python/xpath question...

Stefan Behnel stefan.behnel-n05pAM at web.de
Thu Jul 6 12:44:37 EDT 2006


bruce wrote:
> for guys with python/xpath expertise..
> 
> i'm playing with xpath.. and i'm trying to solve an issue...
> 
> i have the following kind of situation where i'm trying to get certain data.
> 
> i have a bunch of tr/td...
> 
> i can create an xpath, that gets me all of the tr.. i only want to get the
> sibling tr up until i hit a 'tr' that has a 'th' anybody have an idea as to
> how this query might be created?..

I'm not quite sure how this is supposed to be related to Python, but if you're
trying to find a sibling, what about using the "sibling" axis in XPath?

Stefan



More information about the Python-list mailing list