NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.
All the Perl that's Practical to Extract and Report
Stories, comments, journals, and other submissions on use Perl; are Copyright 1998-2006, their respective owners.
We could wirte a CSS - XPath transator (Score:1)
Reply to This
Re: (Score:1)
Re: (Score:1)
Yes.
Re: (Score:1)
Googling "CSS selector to XPath" gives me pretty few results:
http://groups.google.com/group/behaviour/browse_thread/thread/246782199cea5ce9/
http://www.joehewitt.com/blog/2006-03-20.php [joehewitt.com]
Re: (Score:1)
It should not be very hard. There are not many selectors in CSS2 and they just need to be translated once. Maybe I should write up the equivalents.
Re: (Score:1)
Here you go: How to map CSS selectors to XPath queries [plasmasturm.org].
Re: (Score:1)
What about CSS 3 Selectors (Pseudo classes)? [w3.org] Looks like html/selector.rb implements some of those, e.g.