30 Dec 2013 To force the browser to download a file it would otherwise be capable of rendering revokeObjectURL(url); alert('your file has downloaded! 22 Dec 2009 JavaScript can access the current URL in parts. For this URL: https://css-tricks.com/example/index.html?s=flexbox window.location.protocol