Simple CheatSheet
    • PythonPython
    • DatabaseDatabase
    • Operating SystemOperating System
    • ProgrammingProgramming
    • Linux CommandLinux Command
    • ToolkitToolkit
    • OtherOther
    • Keyboard ShortcutsKeyboard Shortcuts
Dart
Dart
HTML Canvas
HTML Canvas
Redis
Redis
Bash
Bash
JavaScript
JavaScript
jQuery

jQuery Selectors

Forms

  • :button
  • :checkbox
  • :checked
  • :disabled
  • :enabled
  • :focus
  • :file
  • :image
  • :input
  • :password
  • :radio
  • :reset
  • :selected
  • :submit
  • :text

Child Filters

  • :first-child
  • :first-of-type
  • :last-child
  • :last-of-type
  • :nth-child()
  • :nth-last-child()
  • :nth-last-of-type()
  • :nth-of-type()
  • :only-child
  • :only-of-type()

Attribute

  • [name|="value"]
  • [name*="value"]
  • [name~="value"]
  • [name$="value"]
  • [name="value"]
  • [name!="value"]
  • [name^="value"]
  • [name]
  • [name="value"][name2="value2"]

Basic Filters

  • :animated
  • :eq()
  • :even
  • :first
  • :gt()
  • :header
  • :lang()
  • :last
  • :lt()
  • :not()
  • :odd
  • :root
  • :target

Basics

  • *
  • .class
  • element
  • #id
  • :hidden
  • :visible
  • :contains()
  • :empty
  • :has()
  • :parent
  • parent > child
  • ancestor descendant
  • prev + next
  • prev ~ siblings

Examples

$("button").click(() => {
    $(":button").css("color", "red");
});

#Combining selectors

$("selector1, selector2 ...selectorn")
Comments
Related
  • Miscellaneous
  • jQuery Ajax
  • jQuery Effects
  • jQuery Events
  • jQuery Traversing
  • jQuery Manipulation
  • jQuery Attributes
  • jQuery Selectors
  • Getting Started