What is a standardized alternative to window.location.href property? I was checking on w3schools.com that it is implemented in all major browsers so there’s no problem but I’m rather curious how to do that properly.
From here is the statement that the function is not standardized: https://developer.mozilla.org/en/DOM/window.location
Thanks!
The
windowobject goes back as far as the original JavaScript implementation in Netscape 2.0, andlocationhas existed in every browser since then.The Browser Object Model outside of the DOM has tradionally not been standardised, but that changes with HTML5, which documents the
windowobject and itslocationproperty explicitly.