mTu*_*ran 2 css jquery css-selectors
我想用jQuery选择除myclass之外的所有h1标签.例如,我想选择<h1>,但我不想选择<h1 class ="myclass">
谢谢
Gum*_*mbo 5
尝试:not()选择器或not方法:
:not()
not
$("h1:not(.myclass)") $("h1").not(".myclass")
Tim*_*Tim 5
$("h1:not('.myclass')")
http://api.jquery.com/not-selector/
归档时间:
15 年,8 月 前
查看次数:
70 次
最近记录: