This week's book giveaway is in the General Computing forum.
We're giving away four copies of Arduino in Action and have Martin Evans, Joshua Noble, and Jordan Hochenbaum on-line!
See this thread for details.
The moose likes Servlets and the fly likes how to insert image in jsp Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


JavaRanch » Java Forums » Java » Servlets
Reply Bookmark "how to insert image in jsp" Watch "how to insert image in jsp" New topic
Author

how to insert image in jsp

s vijay
Greenhorn

Joined: Aug 27, 2001
Posts: 4
can any one give me some sample code on how to insert a image in to jsp page.
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12324
    
    1
Remember two things:
1. JSP builds a HTML page - to add images, etc you have to have your JSP create normal HTML markup. If you are having problems, make a static HTML page that does what you want first.
2. JSP output is naturally character oriented because out is automatically created as a JSPWriter. You can't write binary data such as an image or PDF file with a Writer.
Bill
------------------
author of:


Java Resources at www.wbrogden.com
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: how to insert image in jsp
 
Similar Threads
insert and retrieve image from database.
how to store/retrive image in oracle database using struts 1.2
inserting image
Struts
Insert jpeg files in the database column