首頁  >  文章  >  web前端  >  jQuery有哪些選擇器

jQuery有哪些選擇器

coldplay.xixi
coldplay.xixi原創
2020-11-16 16:24:208932瀏覽

jQuery選擇器:1、層次選擇器;2、基本過濾器選擇器;3、內容過濾器選擇器;4、可見性過濾器選擇器;5、屬性過濾器選擇器。

jQuery有哪些選擇器

推薦:《jquery影片教學

jQuery選擇器:

1、基本的有id、標籤、類別、通配符選擇器:

#id
element
.class
*

2、層次選擇器:

ancestor descendant
parent > child
prev + next
prev ~ siblings

#3、基本過濾器選擇器

:first
:last
:not
:even
:odd
:eq
:gt
:lt
:header
:animated

4、內容過濾器選擇器

:contains
:empty
:has
:parent

5、可見性過濾器選擇器

:hidden
:visible

6、屬性篩選器選擇器

[attribute]
[attribute=value]
[attribute!=value]
[attribute^=value]
[attribute$=value]
[attribute*=value]
[attrSel1][attrSel2][attrSelN]

7、子元素篩選器選擇器

:nth-child
:first-child
:last-child
:only-child

8、表單選擇器

:input
:text
:password
:radio
:checkbox
:submit
:image
:reset
:button
:file
:hidden

9、表單篩選器選擇器

:enabled
:disabled
:checked
:selected

相關免費學習推薦:JavaScript(影片)

#

以上是jQuery有哪些選擇器的詳細內容。更多資訊請關注PHP中文網其他相關文章!

陳述:
本文內容由網友自願投稿,版權歸原作者所有。本站不承擔相應的法律責任。如發現涉嫌抄襲或侵權的內容,請聯絡admin@php.cn
上一篇:jquery怎麼導入下一篇:jquery怎麼導入