The hash property returns a string that starts with a " # " followed by the fragment identi-
fiers. It returns an empty string if there are no fragment identifiers:
The origin property returns a string that shows the protocol and domain where the cur-
rent page originated from. This property is read-only, so cannot be changed:
The window.location object also has these methods:
• The window.location.reload() method can be used to force a reload of
the current page. If it's given a parameter of true , it will force the browser to re-
load the page from the server, instead of using a cached page.
• The window.location.assign() method can be used to load another re-
source from a URL provided as a parameter, for example:
• The window.location.replace() method is almost the same as the win-
dow.location.assign() method, except that the current page will not be
stored in the session history, so the user will be unable to navigate back to it using
the back button.
Search WWH ::