I have a table where each row has a CSS id like this:
... ... .. 3条回答 独厮守ぢ (楼主) 2020-12-10 10:27 you can use this. $('.anotherclass').click(function () { alert($(this).parents('tr').attr("id")); }); 0 讨论(0) 查看其它3个回答 发布评论: 提交评论 加载中... 验证码 看不清? 提交回复 热议问题
you can use this.
$('.anotherclass').click(function () { alert($(this).parents('tr').attr("id")); });