I have a xml like
Text
Number
Use the local-name() function like so:
//*[local-name()='child2']
You can bind any prefix you like (say banana) to the namespace "http://foo"
, and the expression /root/banana:child2
will find the child2 element, regardless what namespace prefix has been used in the source document. Only the namespace URI has to match.