Complete HTML path:
Http: // 10.10.3.117: 8500/html/Ypt/index.html
Alert ("document. Location. href:" + document. Location. href );
Description: sets or returns the host name and the port number of the current URL.
Result: http: // 10.10.3.117: 8500/html/Ypt/index.html
Alert ("document. Location. Hash:" + document. Location. Hash );
Description: sets or returns the URL (Anchor) starting with)
Result:
Alert ("document. Location. HOST:" + document. Location. HOST );
Description: sets or returns the host name and the port number of the current URL.
Result: 10.10.3.117: 8500
Alert ("document. Location. hostname:" + document. Location. hostname );
Description: sets or returns the Host Name of the current URL.
Result: 10.10.3.117
Alert ("document. Location. pathname:" + document. Location. pathname );
Description: sets or returns the path of the current URL.
Result:/html/Ypt/index.html
Alert ("document. Location. Port:" + document. Location. Port );
Description: set or return the port number of the current URL.
Result: 8500