So there isn't any easy way to do this without using java?  I was just
wanted to use a different url and have them served up correctly.  Can you
give me/point me to an example of what you are talking about below?

Thanks,
Susan

-----Original Message-----
From: Caldarale, Charles R [mailto:chuck.caldar...@unisys.com] 
Sent: Wednesday, June 17, 2009 11:33 AM
To: Tomcat Users List
Subject: RE: Serving images from classes directory

> From: Susan G. Conger [mailto:sus...@bfcassociates.com]
> Subject: Serving images from classes directory
> 
> I need to be able to serve images from the classes directory 
> of my web app.

Try using ClassLoader.getResourceAsStream() to read the image, then write it
to the response output stream.  You'll need to set the content-type header
appropriately, of course.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you received
this in error, please contact the sender and delete the e-mail and its
attachments from all computers.

 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to