Friday, July 14, 2017

I don't want users to have to explicitly allow pop-ups in Google Chrome to be able to download a file I present from JavaScript.

Grrr. Pesky pop-up blocker! It's not that hard to sidestep as it turns out. This...

window.open("http://www.example.com/cat.jpg");

 
 

...just needs to become this:

window.open("http://www.example.com/cat.jpg", '_blank');

No comments:

Post a Comment