下面的代码选择我要在其中选择<td>
标记的<a>
。我怎样才能获得<a>
?
var refresh_link = $(this).parent().next().next()
标记:当我单击TEXT LINK A时,我想选择TEXT LINK B
<tr>
<!-- product id -->
<td>6005</td>
<!-- product name -->
<td>
Bla bla text<br />
</td>
<!-- monthly or daily price -->
<td>
270.0€ / mois
</td>
<!-- quantity + hidden field with the rowid + hidden field with original price at pageload -->
<td>
TEXT LINK A
</td>
<!-- rental duration -->
<td>
bla
</td>
<!-- refresh / update cart quantity or duration -->
<td><a id="1" href='#'>bla</a></td>
<!-- total price calculated -->
<td class='price_tot'>
TEXT LINK B
</td>
<!-- send to trash -->
<td><a href='#'>trash</a></td>
</tr>
答案 0 :(得分:4)
这个怎么样:
var refresh_link = $(this).parent().next().next().find('a');