File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JSP and the fly likes dispaly image in jsp page Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "dispaly image in jsp page" Watch "dispaly image in jsp page" New topic

dispaly image in jsp page

ramesh poorella
Ranch Hand

Joined: Jul 19, 2011
Posts: 61
please tell me how to display barcode in jsp page.... i have a barcode image in my system file... i am using img tag in my jsp.... but it is not displaying..
please help me..

this is my code. e.jpeg is barcode image

<p> </p>
<div align="center">
<IMG SRC="C:\Images\e.jpeg" width="200" height="100" >
<table border="0" cellpadding="0" cellspacing="0" width="460" bgcolor="#EEFFCA">

<td width="100%">

<td width="100%"><b>  Date
and time is:  <font color="#FF0000">

<%= new java.util.Date() %>

<input type="submit" value="PRINT" name="print" />

please give me to suggession how to display that

tang jizhong

Joined: Jul 19, 2011
Posts: 1
Hello, you should be in your next project to create a images directory, and e.jpeg put inside. Then use the images / e.jpeg this relative path for a visit.
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63873

You cannot use a file path. You need to use the URL to the image as it served by the container.

[Asking smart questions] [About Bear] [Books by Bear]
I agree. Here's the link:
subject: dispaly image in jsp page
It's not a secret anymore!