To get information related to user's display and other screen properties
This object is has no programmatic use; it used purely to get information about the client's screen capabilities such as width , height , color-depth etc
The information is collected by site tracking tools that measure the capabilities of the client, but has no effect on the functionality
The best possible use of screen object's properties is to
Table : Properties and Methods of history Object
|availHeight||The height of the screen available for the purpose of displaying windows(excluding toolbars, menubars and so on)||number|
|availWidth||The width of the screen available for the purpose of displaying windows (excluding toolbars, menubars and so on)||number|
|colorDepth||To color depth of the screen||number|
|height||To height if the screen||number.|
|width||To width of the screen||number|
To history object methods back() , forward() and go() are used to tell the browser to naviagte to specified URL in history.
The methods back() and forward() have the same effect as the browser's back and forward button.
The method go() is used to navigate to a URL in history relative to the current document.A positive value is used to move forward in the history while a negative value is used to move backwards.
Eg: the value "-2 " will move to a location two steps backward relative to current location, and value " 2 " moves two steps forward relative to current location.
1. The URL address must be from the same server name and port as the current document.
2. One way to add URLs is to make use of query string or hash fragment appended to the current document.
In the below demo, we have stored complex data in the browser history using pushstate() method.