« Return to the main article
Is it possible to force a download path/filename?
I saw a suggestion to use something like:
response.setHeader( "Content-Disposition", "attachment; filename=\"" + localPath + filename + "\";");
but it doesn't seem to work.... it gives to the fiel the name of the SERVLET, instead.
If I take away the "filepath" it works in the LAST USED DIRECTORY!
Any idea?
Is it possible to force a download path/filename?
I saw a suggestion to use something like:
response.setHeader( "Content-Disposition", "attachment; filename=\"" + localPath + filename + "\";");
but it doesn't seem to work.... it gives to the fiel the name of the SERVLET, instead.
If I take away the "filepath" it works in the LAST USED DIRECTORY!
Any idea?