Home Ask Login Register

Developers Planet

Your answer is one click away!

NunoRibeiro February 2016

Javascript download file force prompt destination

I'm downloading a file via javascript (the file is generated on the server) and I want to force the browser to prompt the user to choose the destination of the file. Is it possible? For instance, Chrome as an option with a default folder and I want to be able to override that option

EDIT (explaining the duplicate question) I think it's not a duplicate because I know why the dialog is not opening, just want to ask if the behavior can be overriden


deceze February 2016

You cannot override the download behaviour. A number of modern browsers save any download into a default location without prompting the user. That's how they download files, period. You cannot override this. It's a user choice in the browser's preferences whether they want to be prompted or not.

Post Status

Asked in February 2016
Viewed 2,112 times
Voted 6
Answered 1 times


Leave an answer

Quote of the day: live life