jQuery [attribute!= value]セレクター

❮jQueryセレクター

値が「intro」のクラス属性を含まないすべての<p>要素を選択します。

$("p[class!='intro']")

定義と使用法

[attribute!= value]セレクターは、指定された属性と値を持たない各要素を選択します。

選択された属性を持つが、値が異なる要素が選択されます。


構文

$("[attribute!='value']")

Parameter Description
attribute Required. Specifies the attribute to find
value Required. Specifies the value to find

❮jQueryセレクター