Link to home
Start Free TrialLog in
Avatar of lucavilla
lucavillaFlag for Italy

asked on

XPath for extracting all the element+attribute nodes

This is my XML test text:
"<memo author="Pat Coleman"><to>Carole Poland</to></memo>"

How can I get with XPath/XML DOM a node-set containing all the element and attribute nodes?

is   $obj.selectNodes('//@*|//*')   the shortest/most efficient solution?
ASKER CERTIFIED SOLUTION
Avatar of Gertone (Geert Bormans)
Gertone (Geert Bormans)
Flag of Belgium image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of lucavilla

ASKER

Fantastic answer! thanks!   A+++++