The Navigator Object

The navigator object contains information about the browser. Note: There is no public standard that applies to the navigator object, but all major browsers support it. Navigator Object Properties Property Description appCodeName Returns the code name of the browser appName Returns the name of the browser appVersion Returns the version information of the browser cookieEnabled Determines […]

The Location Object

The location object contains information about the current URL. The location object is part of the window object and is accessed through the window.location property. Note: There is no public standard that applies to the location object, but all major browsers support it. Location Object Properties Property Description hash Sets or returns the anchor part (#) […]

DOM HTMLCollection

An HTMLCollection object is an array-like list of HTML elements. Methods like the getElementsByTagName() returns an HTMLCollection. Properties and Methods The following properties and methods can be used on a HTMLCollection object: Property / Method Description item() Returns the element at the specified index in an HTMLCollection length Returns the number of elements in an […]

The History Object

The history object contains the URLs visited by the user (within a browser window). The history object is part of the window object and is accessed through the window.history property. Note: There is no public standard that applies to the history object, but all major browsers support it. History Object Properties Property Description length Returns the […]

The Storage Object

The Storage object of the Web Storage API provides access to the session storage or local storage for a particular domain. This allows you to read, add, modify, and delete stored data items. Storage Object Properties and Methods Property/Method Description key(n) Returns the name of the nth key in the storage length Returns the number of […]

The HTML DOM Document Object

When an HTML document is loaded into a web browser, it becomes a document object. The document object is the root node of the HTML document. Document Object Properties and Methods The following properties and methods can be used on HTML documents: Property / Method Description activeElement Returns the currently focused element in the document addEventListener() […]

The Console Object

The Console object provides access to the browser’s debugging console. Console Object Methods Method Description assert() Writes an error message to the console if the assertion is false clear() Clears the console count() Logs the number of times that this particular call to count() has been called error() Outputs an error message to the console […]

The HTML DOM Attribute Object

The Attr Object In the HTML DOM, the Attr object represents an HTML attribute. An HTML attribute always belongs to an HTML element. The NamedNodeMap Object In the HTML DOM, the NamedNodeMap object represents an unordered collection of an elements attribute nodes. Nodes in a NamedNodeMap can be accessed by name or by index (number). Properties and Methods Property […]