I placed a button on my page with this code:
onclick=location.href='/myfolder/myfile.zip'
This will show the download window for the file when I press the button.
OK, so now I want to close the popup window.
onclick=window.close()
Yes, now I want to show the downloaded file window, and then close the window.
onclick=location.href='/myfolder/myfile.zip';window.close();
NO, this does not work. It only closes the window. Why?
Pleeeeease tell me. I am a VB programmer, not a JS programmer.
onclick=location.href='/myfolder/myfile.zip'
This will show the download window for the file when I press the button.
OK, so now I want to close the popup window.
onclick=window.close()
Yes, now I want to show the downloaded file window, and then close the window.
onclick=location.href='/myfolder/myfile.zip';window.close();
NO, this does not work. It only closes the window. Why?
Pleeeeease tell me. I am a VB programmer, not a JS programmer.