Easy Tutorial
❮ Met Node Lookupnamespaceuri Prop Documenttype Entities ❯

XML DOM substringData() Method



Definition and Usage

The substringData() method retrieves data from a text node.

Syntax

Parameter Description
start Required. Specifies where to start extracting characters. The starting value is 0.
length Required. Specifies how many characters to extract.

Example

The following code snippet uses loadXMLDoc() to load "books.xml" into xmlDoc and retrieves a fragment from the text node of the first <title> element:

Example

Output:


❮ Met Node Lookupnamespaceuri Prop Documenttype Entities ❯