I'm not experienced with Objective-C, but please give this a try.
The TFHppleElement's parent
property is itself a TFHppleElement, so it in turn has a parent
. If you keep going up through these parents, you should eventually find the node you're looking for. For example to get a parent 2 levels up:
TFHppleElement *table = [[element parent] parent];
Since your XPath will only locate td
s that are two levels under a table (and indeed, that's the only place they should be), then retrieving the parent's parent should get you the table you're looking for.