This week's book giveaway is in the Agile forum.
We're giving away four copies of The Software Craftsman and have Sandro Mancuso on-line!
See this thread for details.
The moose likes JSP and the fly likes File linking Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of The Software Craftsman this week in the Agile forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "File linking" Watch "File linking" New topic

File linking

Sandeep Patel

Joined: Jan 16, 2009
Posts: 11
how to link a file ( which can be any thing an Excel or a Word document) in JSP code? But in the file i want to take values from database (oracle 9i)? How should i go about?
Bauke Scholtz
Ranch Hand

Joined: Oct 08, 2006
Posts: 2458
You can use the HTML <a> element for this. It should point to a valid URL of the file. Which can just be a public resource or a Servlet which reads an inputstream of the file from somewhere (local file system or database or auto-generated) and writes it to the outputstream of the response.
Have you tried LearnNowOnline?
subject: File linking