Easy Tutorial
❮ Dom Prop Node Nodename Prop Element Namespaceuri ❯

XML DOM nodeName Property



Definition and Usage

The nodeName property returns the tag name of the selected element.

Syntax


Example

The following code snippet uses loadXMLDoc() to load "books.xml" into xmlDoc and retrieves the tag name from the first <title> element:

Example

The above code will output:

❮ Dom Prop Node Nodename Prop Element Namespaceuri ❯