Easy Tutorial
❮ Met Element Insertbefore Dom Prop Document Implementation ❯

XML DOM data Attribute



Definition and Usage

The data attribute returns the data of the selected node.

Syntax


Example

The following code snippet uses loadXMLDoc() to load "books_cdata.xml" into xmlDoc and retrieves data from all <html> elements:

Example

The above code will output:


❮ Met Element Insertbefore Dom Prop Document Implementation ❯