wood burning stoves 2.0
The moose likes Servlets and the fly likes Accessing Files From Servlets Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide 1Z0-808 this week in the OCAJP forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Accessing Files From Servlets" Watch "Accessing Files From Servlets" New topic

Accessing Files From Servlets

abhijit salvithal

Joined: May 19, 2005
Posts: 7
hi all,

I have a problem. When try to create file instance form File(URI) constructor of file.
I m creating URI by passing string url to URI like http://localhost:8080/testApp/myFile.txt
when i type this on browser i can see the file but i not able to access via File by passing the same uri.

Thanks in Advance & Regards,
Ben Souther

Joined: Dec 11, 2004
Posts: 13410


Can you tell us what you mean by "access" the file?
Are you trying to download it?

Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
Don't get me started about those stupid light bulbs.
subject: Accessing Files From Servlets