Location Class

Location class

Location objects provide a representation of the address of the active document of their Document’s browsing context, and allow the current entry of the browsing context’s session history to be changed, by adding or replacing entries in the history object.

public sealed class Location : DOMObject

Properties

NameDescription
Hash { get; set; }
Host { get; set; }
Hostname { get; set; }
Href { get; set; }
Origin { get; }
Pathname { get; set; }
Port { get; set; }
Protocol { get; set; }
Search { get; set; }

Methods

NameDescription
Assign(string)Navigates to the given page.
virtual GetPlatformType()This method is used to retrieve the ECMAScript object .
Reload()Reloads the current page.
Replace(string)Removes the current page from the session history and navigates to the given page.
override ToString()

See Also