xml getElementsByTagName w/o recursion?
wsr2 at swbell.net
Wed Feb 11 15:04:47 CET 2004
In article <ab4c5633.0402110336.4d786ff6 at posting.google.com>, sdahlbac at abo.fi
> this is perhaps not directly a python question, but how do I get a
> direct child element without going down the tree and possibly find
> another element with the same name there?
> <name>This is the interesting part</name>
> <name>this is what I DO NOT want</nameA
> I am using xml.dom.minidom and I was thinking along the line of
> but that doesn't work..
> is the only solution to write an own helper function that iterates the
> child nodes and get the correct one?
You need to loop through the children of the node and build a list of the nodes
More information about the Python-list