All Selector (“*”)
Selects all elements.
Selects all elements.
Select all elements that are in the progress of an animation at the time the selector is run.
Selects elements that have the specified attribute with a value either equal to a given string or starting with that string followed by a hyphen (-).
Selects elements that have the specified attribute with a value containing the a given substring.
Selects elements that have the specified attribute with a value containing a given word, delimited by spaces.
Selects elements that have the specified attribute with a value ending exactly with a given string. The comparison is case sensitive.
Selects elements that have the specified attribute with a value exactly equal to a certain value.
Select elements that either don’t have the specified attribute, or do have the specified attribute but not with a certain value.
Selects elements that have the specified attribute with a value beginning exactly with a given string.
Selects all button elements and elements of type button.
Selects all elements of type checkbox.
Matches all elements that are checked or selected.
Selects all direct child elements specified by “child” of elements specified by “parent”.
Selects all elements with the given class.
Select all elements that contain the specified text.
Selects all elements that are descendants of a given ancestor.
Selects all elements that are disabled.
Selects all elements with the given tag name.
Select all elements that have no children (including text nodes).
Selects all elements that are enabled.
Select the element at index n within the matched set.
Selects even elements, zero-indexed. See also odd.
Selects all elements of type file.
Selects all elements that are the first child of their parent.
Selects all elements that are the first among siblings of the same element name.
Selects the first matched element.
Selects element if it is currently focused.
Select all elements at an index greater than index within the matched set.
Selects elements that have the specified attribute, with any value.
Selects elements which contain at least one element that matches the specified selector.
Selects all elements that are headers, like h1, h2, h3 and so on.
Selects all elements that are hidden.
Selects a single element with the given id attribute.
Selects all elements of type image.
Selects all input, textarea, select and button elements.
Selects all elements of the specified language.
Selects all elements that are the last child of their parent.
Selects all elements that are the last among siblings of the same element name.
Selects the last matched element.
Select all elements at an index less than index within the matched set.
Matches elements that match all of the specified attribute filters.
Selects the combined results of all the specified selectors.
Selects all next elements matching “next” that are immediately preceded by a sibling “prev”.
Selects all sibling elements that follow after the “prev” element, have the same parent, and match the filtering “siblings” selector.
Selects all elements that do not match the given selector.
Selects all elements that are the nth-child of their parent.
Selects all elements that are the nth-child of their parent, counting from the last element to the first.
Selects all elements that are the nth-child of their parent, counting from the last element to the first.
Selects all elements that are the nth child of their parent in relation to siblings with the same element name.
Selects odd elements, zero-indexed. See also even.
Selects all elements that are the only child of their parent.
Selects all elements that have no siblings with the same element name.
Select all elements that that have at least one child node (either an element or text).
Selects all elements of type password.
Selects all elements of type radio.
Selects all elements of type reset.
Selects the element that is the root of the document.
Selects all elements that are selected.
A selector representing selector passed to jQuery(), if any, when creating the original set.
Selects all elements of type submit.
Selects the target element indicated by the fragment identifier of the document’s URI.
Selects all elements of type text.
Selects all elements that are visible.
Add the previous set of elements on the stack to the current set, optionally filtered by a selector.
Get the children of each element in the set of matched elements, optionally filtered by a selector.
For each element in the set, get the first element that matches the selector by testing the element itself and traversing up through its ancestors in the DOM tree.
Attach a handler to one or more events for all elements that match the selector, now or in the future, based on a specific set of root elements.
Reduce the set of matched elements to those that match the selector or pass the function’s test.
Get the descendants of each element in the current set of matched elements, filtered by a selector, jQuery object, or element.
Reduce the set of matched elements to those that have a descendant that matches the selector or DOM element.
Check the current matched set of elements against a selector, element, or jQuery object and return true if at least one of these elements matches the given arguments.
Attach an event handler for all elements which match the current selector, now and in the future.
Get the immediately following sibling of each element in the set of matched elements. If a selector is provided, it retrieves the next sibling only if it matches that selector.
Get all following siblings of each element in the set of matched elements, optionally filtered by a selector.
Get all following siblings of each element up to but not including the element matched by the selector, DOM node, or jQuery object passed.
Get the parent of each element in the current set of matched elements, optionally filtered by a selector.
Get the ancestors of each element in the current set of matched elements, optionally filtered by a selector.
Get the ancestors of each element in the current set of matched elements, up to but not including the element matched by the selector, DOM node, or jQuery object.
Get the immediately preceding sibling of each element in the set of matched elements, optionally filtered by a selector.
Get all preceding siblings of each element in the set of matched elements, optionally filtered by a selector.
Get all preceding siblings of each element up to but not including the element matched by the selector, DOM node, or jQuery object.
Get the siblings of each element in the set of matched elements, optionally filtered by a selector.
Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements.
Add elements to the set of matched elements.
Insert content, specified by the parameter, after each element in the set of matched elements.
Add the previous set of elements on the stack to the current set.
Insert content, specified by the parameter, to the end of each element in the set of matched elements.
Insert every element in the set of matched elements to the end of the target.
Insert content, specified by the parameter, before each element in the set of matched elements.
Remove the set of matched elements from the DOM.
Remove event handlers previously attached using .live() from the elements.
Hide the matched elements by fading them to transparent.
Bind one or two handlers to the matched elements, to be executed when the mouse pointer enters and leaves the elements.
Get the HTML contents of the first element in the set of matched elements or set the HTML contents of every matched element.
Search for a given element from among the matched elements.
Insert every element in the set of matched elements after the target.
Insert every element in the set of matched elements before the target.
Return a collection of matched elements either found in the DOM based on passed argument(s) or created by passing an HTML string.
Perform an asynchronous HTTP (Ajax) request.
A generic iterator function, which can be used to seamlessly iterate over both objects and arrays. Arrays and array-like objects with a length property (such as a function’s arguments object) are iterated by numeric index, from 0 to length-1. Other objects are iterated via their named properties.
Load data from the server and place the returned HTML into the matched element.
Remove elements from the set of matched elements.
Remove an event handler.
Attach an event handler function for one or more events to the selected elements.
Attach a handler to an event for the elements. The handler is executed at most once per element.
Insert content, specified by the parameter, to the beginning of each element in the set of matched elements.
Insert every element in the set of matched elements to the beginning of the target.
Specify a function to execute when the DOM is fully loaded.
Remove the set of matched elements from the DOM.
Replace each target element with the set of matched elements.
JavaScript provides several built-in datatypes. In addition to those, this page documents virtual types like Selectors, enhanced pseudo-types like Events and all and everything you wanted to know about Functions. You should be able to try out most of the examples below by just copying them to your browser’s JavaScript Console (Chrome, Safari with Develop … Continue reading
Get the current value of the first element in the set of matched elements or set the value of every matched element.
Wrap an HTML structure around each element in the set of matched elements.
Wrap an HTML structure around all elements in the set of matched elements.
Wrap an HTML structure around the content of each element in the set of matched elements.