This week's book giveaway is in the Open Source forum.
We're giving away four copies of RabbitMQ in Depth and have Gavin Roy on-line!
See this thread for details.
The moose likes Struts and the fly likes how to download a file in struts2 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of RabbitMQ in Depth this week in the Open Source forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "how to download a file in struts2" Watch "how to download a file in struts2" New topic

how to download a file in struts2

sathya rajavel

Joined: May 30, 2011
Posts: 8


I have created a file upload and i make the uploaded file to save in folder.

Now once it get uploaded i created a hyperlink by clicking on the link it should get download please send me the full code for download

debraj mallick
Ranch Hand

Joined: Mar 08, 2011
Posts: 188

hi sathya,

the way you upload a file, is same as downloading the file

this is an example of downloading a pdf file (name = sathya.pdf)
hope this link would help you
I agree. Here's the link:
subject: how to download a file in struts2