Hi, I would like to know how I can make a script that just load the page start a download, without any
< 'a href="" >
or anything that involves clicks. I searched everywhere but I did not find it. Greetings
Hi, I would like to know how I can make a script that just load the page start a download, without any
< 'a href="" >
or anything that involves clicks. I searched everywhere but I did not find it. Greetings
uses the window onload event and points the location to the download url
<script type="text/javascript">
window.onload = function() {
window.location = 'url de descarga';
}
</script>
There are many ways to do it, my little grain of sand would be to try something like this:
In your JS create the function that performs the download And on the html you call the function when loading the body with the onload event.
function descarga() {
window.location = 'http://www.jesuministrosymas.com.ve/LOGO.png';
}
<body LANG="es-VE" DIR="LTR" onload="descarga();">
</body>