I have this XML code:
<root>
<node>
</first_child>
</second_child>
</third_child>
</node>
</root>
I need to take all children nodes one by one and save like three Node variable using DOM.
If I use
doc.getElementsByTagName("node");
I take this “node” with all the children, while I need only “first_child, second_child and third_child”
How to obtain this?
1 Answer