Home  >  Article  >  Web Front-end  >  How to use not in jquery

How to use not in jquery

coldplay.xixi
coldplay.xixiOriginal
2020-12-11 14:34:011904browse

How to use not in jquery: The [not()] method returns elements that do not meet certain conditions. This method is usually used to remove one or more elements from the selected element combination. The syntax is [$ (selector).not(criteria,function(index))].

How to use not in jquery

The operating environment of this tutorial: windows7 system, jquery3.2.1 version, thinkpad t480 computer.

Related free learning recommendations: javascript (video) jQuery Tutorial (Video)

How to use not in jquery:

Definition and usage

not() method returns elements that do not meet certain conditions.

  • This method lets you specify a condition. Elements that do not meet the criteria will be returned from the selection, and elements that meet the criteria will be removed.

  • This method is usually used to remove one or more elements from the selected element combination.

  • Tips: The not() method is relative to the filter() method.

Syntax

$(selector).not(criteria,function(index))

How to use not in jquery

##Example

Return No All

elements with class name "intro":

$("p").not(".intro")

The above is the detailed content of How to use not in jquery. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn