User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.0.3705) Build Identifier: Mozilla 1.3.1 If I load an Xml document, and pull out a particular element. If I then use myElement = element.childNodes; It will return to me all descendent nodes, not just child nodes. ie if I had <Parent> <Title> SomeText </Title> <Parent> it will tell me I have two child nodes, when by w3c spec, the Text Node is actually the child of the Title Node ( or grandchild of Parent) Reproducible: Always Steps to Reproduce: 1.load document 2.searchForelementByTagName 3.getChildNodes 4.Look at results Actual Results: I get all the descendant nodes Expected Results: I only want the child nodes
There is a #text node inside <parent> but before the <title> node... (look at the DOM in DOM inspector, and make sure display of whitespace-only nodes is enabled). *** This bug has been marked as a duplicate of 26179 ***
Status: UNCONFIRMED → RESOLVED
Last Resolved: 16 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.