File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes EJB and other Java EE Technologies and the fly likes Displaying image which is located on local disk but not on server Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Displaying image which is located on local disk but not on server" Watch "Displaying image which is located on local disk but not on server" New topic
Author

Displaying image which is located on local disk but not on server

Vijay maske
Greenhorn

Joined: Oct 29, 2010
Posts: 2
I am using struts framework. I want to display an image which at a specific location on local drive but
not on server.

Please help me out how to do it.

I tried giving full path of image location in but not working.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61092
    
  66

Because the browser will use the source of the image element to fetch the image file, it must be able to be served by URL.

If the file itself can't be served for whatever reason, you can write a servlet that reads the file and serves it.

See the Servlet forum as this has been discussed many times.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Displaying image which is located on local disk but not on server