Howdy fellow ranchers, The question I have relates to including GIFs inside of JSPs. When I am testing the JSPs using localhost:8080 the GIFs are found and displayed just fine. But when I attempt to use my JSPs from outside my localhost the JSPs still work but the GIFs are missing. I setup an image directory in directory which contains the JSP. and used "/image/test.gif" but JSPs still cannot locate the gif. It displays the gifs just fine if I define the entire path (i.e. C:\jsp\images\test.gif) but I don't like the idea of having hardcoded paths in my JSP code
Any suggestions..??
------------------ Regards, Travis M. Gibson, SCJP Java Developer www.travismgibson.com travis@travismgibson.com
Regards,<BR>Travis M. Gibson, SCJP<BR>Java Developer<BR>www.travismgibson.com<BR>travis@travismgibson.com
Madhav Lakkapragada
Ranch Hand
Joined: Jun 03, 2000
Posts: 5040
posted
0
generally I have seen that the images can be displayed when you use image/test.gif. I don't think you should use /image/test.gif. However, you shouldn't put them under WEB-INF though! So the dir structure would be: