if tr contains class="productnamecolor colors_productname" i want to select next tr which contains the price details. so i use :
.//a[@class="productnamecolor colors_productname"]/parent::node()/following-sibling::tr
But didn't work. What is wrong with this expression?
HTML :
<tr>
<td valign="top" width="100%">
<a href="unclesamsretailoutlet.com/Trouser-Suspenders-8440015269920-p/…; class="productnamecolor colors_productname" title="Trouser Suspenders, 2323">Trouser Suspenders</a>
</td>
</tr>
thanx in advance.
The parent of your
<a>element is atdelement, and thetdelement doesn't have a following-sibling - certainly not a following sibling that is atr. If you want the next row in the table, useor