我需要得到这个
('th:last').siblings();
正确进入此
的不区域$(document).on("mouseover", "td:not(....)", function()
{
/// further code...
});
这是如何运作的?
答案 0 :(得分:0)
您可以为~
:
$(document).on("mouseover", "td:not(th:last ~ thesiblingTag)", function() {
$('th:last ~ td').css('background', 'red');
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<table>
<tr>
<th>aaa</th>
<td>bbb</td>
</tr>
<tr>
<th>aaa</th>
<td>bbb</td>
</tr>
<tr>
<th>aaa</th>
<td>bbb</td>
</tr>
</table>