Referring to this example: /
How can I update the content of updatedText.xml
when pressing the 'Download' button, just as it does when the 'Save' button in any application?
In this case I just get another updatedText (1).xml
, updatedText (2).xml
and so on.
Moreover it would be nice if it was possible to specify the directory where the updatedText.xml
is saved.
Has someone an idea?
Referring to this example: http://jsfiddle/m9nts8r1/
How can I update the content of updatedText.xml
when pressing the 'Download' button, just as it does when the 'Save' button in any application?
In this case I just get another updatedText (1).xml
, updatedText (2).xml
and so on.
Moreover it would be nice if it was possible to specify the directory where the updatedText.xml
is saved.
Has someone an idea?
Share Improve this question asked Oct 28, 2014 at 10:50 wurstbrotrestwurstbrotrest 3291 gold badge7 silver badges17 bronze badges 1- Maybe you can try this lib pixelgraphics.us/downloadify/test.html which prompts the user to replace the file if that file already exists – Saurabh Verma Commented Jun 11, 2015 at 10:39
2 Answers
Reset to default 5You cannot do this. Once the file is downloaded it is on your hard drive. Your web browser does not have the permission to access your file system (just imagine what a mess it would be if a website could look into your files or even change them). I guess you will unfortunately have to live with the newly created files or solve your problem with another technology.
You can do it in chrome browser
download extension from this link https://github./zach-adams/downloads-overwrite-already-existing-files "A chrome extension that sets all downloads to overwrite existing files instead of adding ' (1)', ' (2)', etc." then add extension to chrome this will solve your problem.