in reply to Re^2: Comparing nodes in LibXML
in thread Comparing nodes in LibXML

localname is helpful. I missed it in the documentation. But it is only half the picture as it strips namespace information. Evven though it seems that namespaces are an abomination in XML I need to account for them. I am not generating the XML I have to eat.

Replies are listed 'Best First'.
Re^4: Comparing nodes in LibXML
by tangent (Parson) on Sep 03, 2015 at 03:05 UTC
    You can get the prefix at the same time
    my ($prefix,$name) = ( $node->prefix(), $node->localname() );

      The prefix does not help as it is not unique