interactive xpath
Nov 11, 2005, 03:32am EST
I find debugging xpath expressions
a lot like debugging regular expressions: painful and involving lots of
frustrating “why isn’t anything matching” moments. So I threw together an
interactive xpath tester.
Of course, since this is browser based, it’ll only work in Firefox, but
that’s my most common use of xpath anyway (e.g., in
greasemonkey
scripts).
The page also uses a treewalker and CSS selectors for creating the output tree (most of the code originally from this treewalker demo).
I’m full of w3 standards today.
Brian Slesinsky at Nov 19, 2005, 10:52pm EST
Neat! I like how you highlight terms in the source code as you type. See also my XPath Checker extension, which renders the XPath results. (Probably the best way would be to have tabs that switch between source and rendered views.)
L at Aug 23, 2007, 05:21pm EDT
good work, tony chang.
~L