ers List <[EMAIL PROTECTED]>
Date: Wednesday, November 28, 2001 6:03 AM
Subject: Re: .gif images not displaying with JSPs
>After my initial message, I created an images directory (eg.
>../myapp/images), so using <%=request.getContextPath()%>/images/image1.gif
>results in:
>
e path you get is. Just
>put <%= request.getContextPath() %> before
>
>
>-Original Message-
>From: Mark <[EMAIL PROTECTED]>
>To: Tomcat Users List <[EMAIL PROTECTED]>
>Date: Tuesday, November 27, 2001 11:03 AM
>Subject: RE: .gif images not displaying w
etContextPath() solves the problem to give you
>>an absolute path within the context.
>>
>>example:
>>>src='<%=request.getContextPath()%>/graphics/flags/german_flag.gif'/>>>
>>
>>Hope that helps!
>>
>>Carsten
>>
>>
Just a suggestion, Mark: if you actually showed the directories rather than
saying things like "the root context" or "the same directory as the html and
JSP files" it would be easier, because the relative paths are not the only
issues.
-Original Message-
From: Mark <[EMAIL PROTECTED]>
To:
Well, then, Mark, just get whatever the value of request.getContextPath() is
and hard code it. ??? What do you think, Micael.
From: Mark <[EMAIL PROTECTED]>
To: Tomcat Users List <[EMAIL PROTECTED]>
Date: Tuesday, November 27, 2001 11:03 AM
Subject: RE: .gif images not displayi
ensaje original-
De: Mark [mailto:[EMAIL PROTECTED]]
Enviado el: Martes, 27 de Noviembre de 2001 01:07 p.m.
Para: Tomcat Users List
Asunto: RE: .gif images not displaying with JSPs
Yes, that fixed the problem - thank you!
Takes care of my problem with Tomcat, but it introduces a problem with the
ontext.
>
>example:
>src='<%=request.getContextPath()%>/graphics/flags/german_flag.gif'/>>
>
>Hope that helps!
>
>Carsten
>
>-Original Message-
>From: Mark [mailto:[EMAIL PROTECTED]]
>Sent: Tuesday, November 27, 2001 12:36 PM
>To: Tomcat Users List
>Sub
Sent: Tuesday, November 27, 2001 12:36 PM
To: Tomcat Users List
Subject: Re: .gif images not displaying with JSPs
Can you display images from a JSP? My straight html pages display images
with no problems using Tomcat. What's odd is if I take the html source
generated by the JSP (ie, 'v
Can you display images from a JSP? My straight html pages display images
with no problems using Tomcat. What's odd is if I take the html source
generated by the JSP (ie, 'view source from the browser'), save it as an
html file and re-display it, it's fine. So the html generated by the JSP
seems
g mac Grene [mailto:[EMAIL PROTECTED]]
Enviado el: Martes, 27 de Noviembre de 2001 10:28 a.m.
Para: Tomcat Users List
Asunto: Re: .gif images not displaying with JSPs
I have a directory called graphics on the same level as WEB-INF, i.e.
root_directory/webapps/myapp/graphics/flags/ and
root_dire
I have a directory called graphics on the same level as WEB-INF, i.e.
root_directory/webapps/myapp/graphics/flags/ and
root_directory/webapps/myapp/WEB-INF/, and I use
without dificulty, if that helps. This may have to do with my settings in
server.xml, which is:
Hope this helps.
11 matches
Mail list logo