XML DOM baseURIProperty


Node object

Definition and Usage

The baseURI property returns the absolute base URI of a node.

Syntax

nodeObject.baseURI


Example

The following code snippet usesloadXMLDoc()put "books_ns.xml"Load into xmlDoc, and return the base URI of the <title> element:"

Example

xmlDoc=loadXMLDoc("books_ns.xml"); x=xmlDoc.getElementsByTagName('title'); for(i=0;i<x.length;i++) { document.write(x.item(i).baseURI); document.write(""); }

Try it Yourself »

Node objectother extensions