From http://www.w3schools.com (Copyright Refsnes Data)
Complete Element Object Reference
The ownerDocument property returns the document object the selected element belongs to.
| elementNode.ownerDocument |
The following code fragment loads "books.xml" into xmlDoc using loadXMLDoc() and gets name and node type from the owner document of the first <title> element:
Example
The output of the code above will be:
Try it yourself » |
Complete Element Object Reference
From http://www.w3schools.com (Copyright Refsnes Data)