I am using minidom in Python and I'd like getElementsByTagName() to match elements purely by tag-name and ignore any namespaces. The documents are being parsed by minidom.parseString(). Is it possible?
getElementsByTagName
does match elements purely by tagName.
Do you mean you want to match purely on localName? ie. the part of the tag name after the :
(if any)? If so use the DOM Level 2 Core method getElementsByTagNameNS:
els= document.getElementsByTagNameNS('*', 'tag')
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With