Sets or retrieves the entire URL as a string.
Property of dom/Locationdom/Location
Syntaxvar url = location.href;
location.href = url;
Return Value
Returns an object of type StringString
The URL of the document.
ExamplesThis example shows a URL list. The user is taken to the URL selected from the options, if the selection is different from the list’s default value.
<select onchange="window.location.href=this.options[this.selectedIndex].value">
<option value="http://www.microsoft.com/ie">Internet Explorer</option>
<option value="http://www.microsoft.com">Microsoft Home</option>
<option value="http://msdn.microsoft.com">Developer Network</option>
</select>
Attributions
Microsoft Developer Network: [Windows Internet Explorer API reference Article]
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4