velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Barbara Baughman <baugh...@utdallas.edu>
Subject Re: context and images
Date Mon, 05 Aug 2002 15:22:17 GMT
Your relative path should be relative to the file from which you are
calling the image.  For example, if the template is
...webapps/templates/welcome.vm, and the image is in
...webapps/images/logo.png, then the code would be:
<img src="../images/logo.png">

This has nothing to do with Velocity.  It's the way HTML works.

Barbara Baughman
X2157

On Mon, 5 Aug 2002, Tomasz Mielnik wrote:

> i know that this is a little offtopic but i'm going crazy with this.
> i have context in Tomcat "/webapp" and diferent servlets in this context
> (for example /webapp/servlet/showTemplate).
> in Velocity template i have a lot of pictures (pngs jpgs) but all with 
> relativ path
> 
> <img src="images/logo.png">
> 
> when i call servlet i can se no pictures ofcoz sine they have relative 
> paths.
> i dont want to add /webapp/images inforont of images form several 
> reasons. is there a solution for this?
> 
> TIA
> 
> Tomasz Mielnik / Tdc Internet Polska
> 
> 
> --
> To unsubscribe, e-mail:   <mailto:velocity-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: <mailto:velocity-user-help@jakarta.apache.org>
> 
> 


--
To unsubscribe, e-mail:   <mailto:velocity-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:velocity-user-help@jakarta.apache.org>


Mime
View raw message