我需要找到单击另一个图像按钮(在表格单元格2内)的图像按钮(在表格单元格1内)的id。如何使用jquery在html表中找到元素的ID
我无法在javascript/jquery中对任何索引进行硬编码。
是否有任何其他方式来获取该特定行内的第二个按钮的ID?
请帮
代码示例
<tr class="home-history-grid-row">
<td>
<img id="test" height="16px" width="16px" onclick="changeImage(this)" src="SiteImages/deleteconfirm.png" title="Confirm Delete" alt="Delete">
</td>
<td>
<input id="ctl00_Content_NotificationHistory_ctl02_ImgDelete" type="image" style="height: 16px; width: 16px; border-width: 0px;" src="SiteImages/X.gif" clientidmode="Static" disabled="disabled" name="ctl00$Content$NotificationHistory$ctl02$ImgDelete">
</td>
</tr>
u能请提供的HTML代码? –
@Umesh请找到最新的问题。 – NewBie