Created
March 12, 2012 00:19
-
-
Save toamitkumar/2018815 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* The code on the server side has content disposition as attachment | |
* It adds a cookie for the filedownload status | |
* remember to flush the response | |
*/ | |
response.setHeader("Content-Disposition", "attachment; filename="+downloadFileName); | |
Cookie cookie = new Cookie("fileDownloadStatus", "complete"); | |
cookie.setPath("/"); | |
response.addCookie(cookie); | |
response.flushBuffer(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment