This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Struts and the fly likes download content is outputting to my browser not creating a download file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "download content is outputting to my browser not creating a download file" Watch "download content is outputting to my browser not creating a download file" New topic
Author

download content is outputting to my browser not creating a download file

Mark Tobin
Ranch Hand

Joined: May 05, 2010
Posts: 37
Hi I am trying to download file of xml created by my application.

I have the following action



Instead of getting the downlaod prompt TestResults are outputted straight onto my browser
Mark Tobin
Ranch Hand

Joined: May 05, 2010
Posts: 37
You need to force it, it will default to the browser since it is XML

so need the following


Added attachment
 
wood burning stoves
 
subject: download content is outputting to my browser not creating a download file
 
Similar Threads
PDF download Using Struts
Download file issue
downloading a file ok; also want to navigate to another page in the same action not sure how to
StreamResult changes file name during download on Mobile phone
Browser gets refreshed after file download in Struts2