0
I have a folder in the cloud, and I want to generate a list in the html paginal, with all these files, so that when the user clicks, open the downlaod of the file, I am trying as follows(this code is only for testing):
<a href="http://zulex.com.br/upload/CLIDET.DBF" download>
<img border="0" src="/images/myw3schoolsimage.jpg" alt="W3Schools" width="104" height="142">
</a>
in Chrome works, opens the download window, however in firefox and in IE, the browser try to open file, instead of opening the download screen, how can I improve this code?
Not all browsers even support, this can be seen here. On the tab "known issues" says Firefox supports only same-origin.
– Renan Gomes
This then is a behavior of the browser trying to run instead of downloading what it already knows how to open, take as an example the . pdf that opens in the browser instead of being downloaded to your machine many times. I don’t know if it can help you, but it has a good library to "force" the download to Filesaver.js if it helps you https://github.com/eligrey/FileSaver.js/
– Giovane