XML DOM - NodeList object

NodeList object represents an ordered list of nodes.

NodeList object

We can access the nodes in the node list by the node index number (starting from 0).

The node list can maintain its own updates. If a node list or an element in the XML document is deleted or added, the list will also be automatically updated.

Note:In a node list, the order of nodes returned is the same as the order in which they are specified in XML.

IE: Internet Explorer: F: Firefox: O: Opera: W3C: World Wide Web Consortium (Internet standards)

Attributes of NodeList object

Attribute Description IE F O W3C
length Can return the number of nodes in the node list. 5 1 9 Yes

Methods of NodeList object

Method Description IE F O W3C
item() Can return the node at the specified index number in the node list. 5 1 9 Yes