XML.parentNode Property

ActionScript for Flash MX: The Definitive Guide, 2nd Edition
By Colin Moock
Chapter 18.  ActionScript Language Reference
XML.parentNode Property Flash 5

a reference to the immediate ancestor of a node read-only
theNode.parentNode

Description

The parentNode property returns a reference to the node object from which theNode descends in the XML object hierarchy, where theNode can be an XML or XMLnode instance. If theNode is the top (root) node of the current hierarchy, parentNode returns null.

In this XML source fragment, the MESSAGE node is the parentNode of text node "hey":

<MESSAGE>hey</MESSAGE>

Here, the parentNode of the ROOM node is the HOTEL node:

<HOTEL><ROOM><SIZE>Double</SIZE></ROOM></HOTEL>

See Also

XML.childNodes, XML.firstChild, XML.lastChild, XML.previousSibling



    ActionScript for Flash MX. The Definitive Guide
    ActionScript for Flash MX: The Definitive Guide, Second Edition
    ISBN: 059600396X
    EAN: 2147483647
    Year: 2002
    Pages: 780
    Authors: Colin Moock

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net