• Post Reply Bookmark Topic Watch Topic
  • New Topic

how to download  RSS feed

 
Arun Boraiah
Ranch Hand
Posts: 233
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi i have static excel file on my tomcat server. I want to make this file download from client (browser). Hence i have placed this file inside the tomcat and when i am pointing this file from broswer. I am getting bit code of the excel printed. Instead i want this to be download to local system where user will be asked to download the file.

Example : http://localhost:8090/examples/28rep.xls is the url of the excel file. If user click on this url he/she should able to download this file instead i am getting bit code of the excel printed on the browser.
Please advise.
[ October 28, 2005: Message edited by: Bear Bibeault ]
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Search this forum with keywords "Content-Type" and "Content-Disposition" and you will find plenty of discussion on this topic.

Also, in the JSP Faq, there is a section on Excel. The example it gives is a little different than what you're doing (it builds an HTML table and writes it to the output with Excel headers) but it does have a working example of the code required to set the headers.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!