URL of the window.
Platform Support
| IE | Mozilla | Netscape | Opera | Safari | 3.0+ | 1.0+ | 2.0+ | 7.0+ | 1.0+ |
|---|
Constructors
| Constructor | Action | IE | Mozilla | Netscape | Opera | Safari | ||
|---|---|---|---|---|---|---|---|---|
|
Location Constructor() : Location
Creates a new instance of a Location object.
|
Show Details | 3.0+ | 1.0+ | 2.0+ | 7.0+ | 1.0+ | ||
Location() : LocationCreates a new instance of a Location object. Returns
|
||||||||
Properties
| Property | Action | IE | Mozilla | Netscape | Opera | Safari |
|---|---|---|---|---|---|---|
|
Anchor portion of the URL.
|
No Details | 3.0+ | 1.0+ | 2.0+ | 7.0+ | 1.0+ |
|
|
||||||
|
Host name and port of the URL.
|
No Details | 3.0+ | 1.0+ | 2.0+ | 7.0+ | 1.0+ |
|
|
||||||
|
Host name of the URL.
|
No Details | 3.0+ | 1.0+ | 2.0+ | 7.0+ | 1.0+ |
|
|
||||||
|
Complete text of the URL.
|
No Details | 3.0+ | 1.0+ | 2.0+ | 7.0+ | 1.0+ |
|
|
||||||
|
Path name portion of the URL. (e.g. "/docs/index.html")
|
No Details | 3.0+ | 1.0+ | 2.0+ | 7.0+ | 1.0+ |
|
|
||||||
|
Port portion of the URL.
|
No Details | 3.0+ | 1.0+ | 2.0+ | 7.0+ | 1.0+ |
|
|
||||||
|
Protocol portion of the URL. ("http" or "https")
|
No Details | 3.0+ | 1.0+ | 2.0+ | 7.0+ | 1.0+ |
|
|
||||||
|
Query string portion of the URL.
|
No Details | 3.0+ | 1.0+ | 2.0+ | 7.0+ | 1.0+ |
|
|
||||||
Functions
| Method | Action | IE | Mozilla | Netscape | Opera | Safari | |||||
|---|---|---|---|---|---|---|---|---|---|---|---|
|
reload(Boolean force) : Object
Reloads the current URL.
|
Show Details | 4.0+ | 1.0+ | 3.0+ | 7.0+ | 1.0+ | |||||
|
Parameters
Returns
|
|||||||||||
|
replace(String url) : Object
Replace the document of the current URL with the document from another URL.
|
Show Details | 4.0+ | 1.0+ | 3.0+ | 7.0+ | 1.0+ | |||||
|
Parameters
Returns
|
|||||||||||
References
Availability
JavaScript 1.0|enhanced in JavaScript 1.1
