Neither, actually.  It returns all the elements (not necessarily all the
nodes) that are descendants of the specified element.  From the DOM
spec: "A descendant node of any node A is any node below A in a tree
model of a document, where "above" means "toward the root."  So the list
will include child elements and their children, recursively.

-----Original Message-----
From: Ralph van Etten [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, June 17, 2008 12:16 PM
To: [email protected]
Subject: What does nodes does DOMElement::getElementsByTagName return?

Hi,

I have a question about DOMElement::getElementsByTagName("*").
Does this return a list with all nodes below the element including the 
children of the child nodes or just the child nodes ?
I'm not sure how to interpret what it says in the documentation but I 
think it also returns the children of the child nodes. Is this correct ?

Thanks,

Ralph.

Reply via email to