Селектор по несовпадению с атрибутом [name!=”value”]


Содержание:

attributeNotEqual selector

Описание: Select elements that either don't have the specified attribute, or do have the specified attribute but not with a certain value.

  • Добавлен в версии: 1.0jQuery( "[attribute!='value']" )

    attribute: An attribute name.

    value: An attribute value. Can be either a valid identifier or a quoted string.

This selector is equivalent to :not([attr='value']).

Дополнительные замечания:

  • Because [name!="value"] is a jQuery extension and not part of the CSS specification, queries using [name!="value"] cannot take advantage of the performance boost provided by the native DOM querySelectorAll() method. For better performance in modern browsers, use $( "your-pure-css-selector" ).not( "[name='value']" ) instead.