Quanta Plus -- XML Editor for Ubuntu
# select all descendants of node parent
/parent/*//
http://www.tizag.com/xmlTutorial/xpathdescendant.php
$ sudo apt-get install python-4suite-xml
$ 4xpath --string book.xml /catalog/book/author
Result (XPath string):
======================
Gambardella, Matthew
http://www.whitebeam.org/library/guide/TechNotes/xpathtestbed.rhtm
Simply Python code
http://stackoverflow.com/questions/8692/how-to-use-xpath-in-python
import libxml2
doc = libxml2.parseFile('foo.xml')
for url in doc.xpathEval('//@Url'):
print url.content
No comments:
Post a Comment