the host name and port number.
The host property is the concatenation of the hostname and port properties, separated by a colon (hostname:port). When the port property is null, the host property is the same as the hostname property.
The host property may be set at any time, although it is safer to set the href property to change a location. If the specified host cannot be found, an error is returned.
This example function returns the host property of the current page location.