frozenpeas
Technical User
I need to make my way to the node "link" which is the child node of "links". No matter what I do, I can't find it. Any ideas?
Once I find "links" I trace hasChildNodes and that returns "true"... but that's as far as it will go. I can't actually read the child node.
So that traces "true"...
I want my function to be:
... but I can't get there. Oh my...
Once I find "links" I trace hasChildNodes and that returns "true"... but that's as far as it will go. I can't actually read the child node.
Code:
function loadLinks () {
for (i=0; i<=this.childNodes.length; i++) {
if (this.childNodes[i].nodeName.toLowerCase() == "links") {
trace (this.childNodes[i].hasChildNodes());
}
}
}
So that traces "true"...
I want my function to be:
Code:
function loadLinks () {
for (i=0; i<=this.childNodes.length; i++) {
if (this.childNodes[i].nodeName.toLowerCase() == "link") {
do what I want;
}
}
}
... but I can't get there. Oh my...