★
❉
u
Holds or releases the execution of jQuery's ready event.
jQuery()
jQ
Accepts a string containing a CSS selector which is then used to match a set of elements. jQuery( selector [, context context]] ) - jQuery( element ) jQuery( object ) - jQuery( elementArray elementArray )) jQuery( jQuery jQuery( jQuery object )
jQuery.noConflict( [removeAll] )
Obj
Relinquish jQuery's control of the $ variable.
jQuery.sub()
jQ
Creates a new copy of jQuery whose properties and methods can be modified without affecting t he original jQuery object.
jQuery.when( deferreds ) Provides a way to execute callback functions based on one or more objects, usually Deferred objects that represent asynchronousevents.
❉
SELECTORS
NEW OR CHANGED IN jQUERY 1.7 / f(x)
Attribute Ends With Selector [name [ name $=" value value"] "]
CORE
jQuery.holdReady( hold )
=
Selects elements that have the specified attribute with a value ending exactly with a given string. The comparison is case sensitive.
Attribute Equals Selector [ name name=" =" value "]
FUNCTION /
a
=
ARRAY / jQ
=
jQUERY / El
=
ELEMENT /
0-1
NUMBER / Str
=
:empty Selector
:last-child Selector Selects all elements that are the last child of their parent.
:enabled Selector
:last Selector
Selects all elements that are enabled.
Selects the last matched element.
STRING
Selects even elements, zero-indexed.
Multiple Attribute Selector [name [ name=" =" value value"] "] [name2 name2=" =" value2 value2"] "]
:file Selector
Matches elements that match all of the specified attribute filters.
Selects all elements of type file.
Multiple Selector (“selector1 (“ selector1,, selector2 selector2,, selectorN”) selectorN ”)
Select elements that either don't have the specified attribute, or do have the specified attribute but not with a certain value.
Attribute Starts With Selector [name name^=" ^=" value value"] "]
:button Selector Selects all button elements and elements of type button.
:checkbox Selector
:even Selector
:first-child Selector
:first Selector Selects the first matched element.
:focus selector
Next Siblings Selector (“prev (“prev ~ ~ siblings siblings”) ”) Selects all sibling elements that follow after the "prev" element, have the same parent, and match the filtering "siblings" selector.
:gt() Selector
:checked Selector
Select all elements at an index greater than index within the matched set.
Selects elements that have the specified attribute, with any value.
:has() Selector
:odd Selector Selects odd elements, zero-indexed zero-indexed..
:parent Selector :hidden Selector
:disabled Selector Selects all elements that are disabled.
:only-child Selector Selects all elements that are the only child of their parent.
Selects all elements that are headers, like h1, h2, h3 and so on.
Select all elements that contain the specified text.
Selects all elements that are descendants of a given ancestor.
:nth-child() Selector Selects all elements that are the nth-child of their parent.
Selects elements which contain at least one element that matches the specified selector.
:header Selector
Descendant Selector (“ancestor (“ ancestor descendant”) descendant ”)
:not() Selector Selects all elements that do not match the given selector.
Has Attribute Selector [ name name]]
:contains() Selector
Next Adjacent Selector (“prev (“ prev + + next next”) ”) Selects all next elements matching "next" that are immediately preceded by a sibling "prev".
Selects element if it is currently focused.
Selects all elements of type checkbox.
Child Selector (“parent (“ parent > child child”) ”)
Selects the combined results of all the specified selectors.
Selects all elements that are the first child of their parent.
Selects all elements with the given class.
Selects elements that have the specified attribute with a value containing a given word, delimited by spaces.
=
Attribute Not Equal Selector [ name name!! =" value value"] "]
Class Selector (“.class (“ .class”) ”)
Attribute Contains Word Selector [name name~=" ~=" value value"] "]
/ NUM
:lt() Selector
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 containing the a given substring.
OBJECT
Select all elements at an index less than index within the matched set.
Selects all direct child elements specified by "child" of elements specified by "parent".
Attribute Contains Selector [name name*=" *=" value value"] "]
=
:eq() Selector
:animated Selector
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 (-).
Obj
Select the element at index n within the matched set.
All Selector (“ *”)
Attribute Contains Prefix Selector [ name name|| =" value value"] "]
BOOLEAN /
Select all elements that have no children (including text nodes).
Matches all elements that are checked. Selects all elements.
=
Selects elements that have the specified attribute with a value exactly equal to a certain value.
Selects elements that have the specified attribute with a value beginning exactly with a given string.
pr
=
Selects all elements that are hidden.
Select all elements that are t he parent of another element, including text nodes.
ID Selector (“#id (“ #id”) ”)
:password Selector
Selects a single element with the given id attribute.
Selects all elements of type password.
:image Selector
:radio Selector
Selects all elements of type image.
Selects all elements of type password.
Element Selector (“element (“ element”) ”)
:input Selector
:reset Selector
Selects all elements with the given tag name.
Selects all input, textarea, select and button elements.
Selects all elements of type reset.
★
=
NEW OR CHANGED IN jQUERY 1.7 / f(x)
:selected Selector
.removeProp( propertyName )
Selects all elements that are selected.
Remove a property for the set of matched elements.
:submit Selector
.toggleClass( className )
Selects all elements of type submit.
Add or remove one or more classes from each element in the set of matched elements, depending on either the class's presence or the value of the switch argument.
=
FUNCTION /
jQ
Selects all elements that are visible.
ARRAY / jQ
=
jQUERY / El
=
ELEMENT /
.filter()
jQ
N
Get the descendants of each element in t he current set of matched elements, filtered by a selector, jQuery object, or element.
a()
.find( selector ) - .find( jQuery .find( jQuery object ) - .find( element )
.val( value .val( value ) - .val( function(index function(index,, value value)) )
jQ
❉
.addClass()
jQ
Str
.attr()
.andSelf() Str
Get the value of an attribute for the first element in the set of matched elements.
jQ
jQ
jQ
Str
.html()
Str
Get the HTML contents of the first element in the set of matchedelements.
jQ
.closest()
jQ
Get the first element that matches the selector, beginning at the current element and progressing up t hrough the DOM tree.
a()
Str
Get the value of a property for the first element in the set of matched elements.
jQ
★ .removeAttr( attributeName )
jQ
.removeClass()
jQ
jQ
jQ
Iterate over a jQuery object, executing a function for each matchedelement.
.end()
Remove an attribute from each element in the set of matchedelements.
jQ
.eq( index )
.removeClass( [className [className]] ) .removeClass(function(index function(index class class)) )
Reduce the set of matched elements to the one at the specifiedindex.
=
NUMBER / Str
=
.not()
jQ
jQ
jQ
jQ
.has()
jQ
Reduce the set of matched elements to those that have a descendant that matches the selector or DOM element.
★ .is()
jQ
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.
.parentsUntil()
jQ
jQ
jQ
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. .parentsUntil( [selector [selector]] [, filter filter]] ) .parentsUntil( [element [element]] [, filter filter]] )
.is( selector ) - .is( function(index function( index)) ) - .is( jQuery .is( jQuery object ) .is( element )
.prev( [selector [selector]] )
.last()
Get the immediately preceding sibling of each element in the set of matched elements, optionally filtered by a selector.
jQ
jQ
Reduce the set of matched elements to the final one in the set. jQ
jQ
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.
.nextUntil( [selector [selector]] [, filter filter]] ) - .nextUntil( [element [element]] [, filter]] ) filter
jQ
Get all preceding siblings of each element up to but not including the element matched by the selector, DOM node, or jQuery object. .prevUntil( [selector [selector]] [, filter filter]] ) .prevUntil( [element [element]] [, filter filter]] )
jQ
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.
jQ
Get all preceding siblings of each element in the set of matched elements, optionally filtered by a selector.
.prevUntil() .next( [selector [selector]] )
.nextUntil()
jQ
STRING
Get the closest ancestor element that is positioned.
.parents( [selector [selector]] )
.nextAll( [selector [selector]] )
End the most recent filtering operation in the current chain and return the set of matched elements to its previous state.
Remove a single class, multiple classes, or all classes from each element in the set of matched elements.
/ NUM
.parent( [selector [selector]] )
Pass each element in the current matched set through a function, producing a new jQuery object containing the return values.
Get the children of each element in t he set of matched elements, including text and comment nodes.
.each( function(index function(index,, Element Element)) )
.prop( propertyName propertyName)) - .prop( propertyName propertyName,, value )
OBJECT
.prevAll( [selector [selector]] )
.html( htmlString ) - .html( function(index function(index,, oldhtml oldhtml)) )
.prop()
=
Reduce the set of matched elements to the first in the set.
.map( callback(index callback(index,, domElement domElement)) )
.closest( selector ) - .closest( selector [, context context]] ) .closest( jQuery .closest( jQuery object ) - .closest( element ) .closest( selectors [ , context ] )
.contents()
Obj
.not( selector ) - .not( elements ) - .not( function(index function( index)) )
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.
Get the children of each element in t he set of matched elements, optionally filtered by a selector.
Determine whether any of the matched elements are assigned the given class.
BOOLEAN /
Remove elements from the set of matched elements.
.has( selector ) - .has( contained )
Add the previous set of elements on the stack to the current set.
.children( [selector] )
.attr( attributeName ) - .attr( attributeName attributeName,, value )
.hasClass( className )
.add() .add( selector ) - .add( elements ) - .add( html ) .add( jQuery .add( jQuery object ) - .add( selector selector,, context )
.addClass( className ) - .addClass( function(index function( index,, currentClass)) ) currentClass
jQ
TRAVERSING
Add elements to the set of matched elements.
Adds the specified class(es) to each of the set of matched elements.
=
.offsetParent() .find( selector )
.first() ❉ ATTRIBUTES
0-1
.filter( selector ) - .filter( function(index function(index)) ) .filter( element ) - .filter( jQuery .filter( jQuery object )
Get the current value of the first element in the set of matched elements.
.val()
:visible Selector
=
Reduce the set of matched elements to those that match the selector or pass the function's test.
:text Selector Selects all elements of type text.
a
.siblings( [selector [selector]] ) jQ
jQ
Get the siblings of each element in the set of matched elements, optionally filtered by a selector.
.slice( start [, end end]] ) Reduce the set of matched elements to a subset specified by a range of indices.
jQ
★
❉
NEW OR CHANGED IN jQUERY 1.7 / f(x)
.hasClass( className )
MANIPULATION
.addClass()
=
jQ
=
FUNCTION /
Str
Determine whether any of the matched elements are assigned the given class.
Adds the specified class(es) to each of the set of matched elements.
.html()
.addClass( className ) - .addClass( function(index function( index,, currentClass curren tClass)) )
Get the HTML contents of the first element in the set of matched elements.
.after()
jQ
Str jQ
jQ
Insert content, specified by the parameter, to the end of each element in the set of matched elements.
.insertAfter( target ) jQ
Insert every element in the set of matched elements to the end of the target.
.attr()
jQ
jQ
ELEMENT /
.remove( [selector [selector]] )
.outerHeight( [includeMargin [ includeMargin]] )
Create a deep copy of the set of matched elements. .clone( [ withDataAndEvents withDataAndEvents]] ) .clone( [ withDataAndEvents withDataAndEvents]] [,deepWithDataAndEvents [,deepWithDataAndEvents] )
.position()
.css()
Str
Get the current coordinates of the first element in the set of matched elements, relative to the offset parent.
Get the value of a style property for the first element in the set of matched elements.
jQ
jQ
.prepend( content [, content content]] )
.prependTo( target ) jQ
Remove the set of matched elements from the DOM. jQ
=
Str
.removeAttr( attributeName )
jQ
Remove an attribute from each element in the set of matchedelements. jQ
BOOLEAN /
Obj
=
OBJECT
/ NUM
=
NUMBER / Str
Str
Get the current value of the first element in the set of matchedelements.
a()
.val( value .val( value ) - .val( function(index function( index,, value value)) )
jQ
.width()
Int
.width( value .width( value ) - .width( function(index function(index,, width width)) )
.wrap()
.removeProp( propertyName )
Wrap an HTML structure around each element in the set of matched elements.
jQ
.wrap( wrappingElement .wrap( wrappingElement)) - .wrap( function(index function(index)) )
jQ
.wrapAll( wrappingElement .wrapAll( wrappingElement )
jQ
Wrap an HTML structure around all elements in the set of matchedelements.
Replace each element in the set of matched elements with the provided new content.
Wrap an HTML structure around the content of each element in the set of matched elements.
.replaceWith( newContent ) - .replaceWith( function )
.wrapInner( wrappingElement)) .wrapInner( wrappingElement .wrapInner( .wrapI nner( function( function(index index)) )
.scrollLeft()
N
Get the current computed width for the first element in the set of matched elements.
.removeClass( [className [className]] ) .remov eClass( eClass( function( function(index index,, class class)) ) jQ
STRING
.val()
Int
Int
=
Remove a single class, multiple classes, or all classes from each element in the set of matched elements.
.replaceAll( target )
jQ
.wrapInner()
jQ
jQ
Get the current horizontal position of the scroll bar for the first element in the set of matched elements.
❉
CSS
.scrollLeft( value .scrollLeft( value ) Int
.addClass() .scrollTop()
jQ
Get the current vertical position of the scroll bar for the first element in the set of matched elements.
Obj
.text()
jQ
.css()
Str
Get the combined text contents of each element in the set of matched elements, including their descendants.
Get the value of a style property for the first element in the set of matched elements.
jQ
.text( textString ) - .text( function(index function(index,, text text)) )
.css( propertyName ) - .css( propertyName propertyName,, value ) .css( pr propertyNam opertyNamee, function(index function(index,, value value)) ) .css( map )
jQ
.toggleClass() jQ
Insert every element in the set of matched elements to the beginning of the target.
jQ
Add or remove one or more classes from each element in the set of matched elements, depending on either the class's presence or the value of the switch argument.
jQuery.cssHooks
Str
Get the value of a property for the first element in the set of matched elements.
jQ
.unwrap() Remove the parents of the set of matched elements from the DOM, leaving the matched elements in their place.
Obj
Hook directly into jQuery to override how particular CSS properties are retrieved or set, normalize CSS property naming, or create custom properties.
.toggleClass( class .toggleClass( className Name ) .toggleClass( .toggle Class( class className Name,, switch )
.prop()
jQ
Adds the specified class(es) to each of the set of matched elements. .addClass( className ) - .addClass( function(index function( index,, currentClass curren tClass)) )
.scrollTop value .scrollTop value )
Insert content, specified by the parameter, to the beginning of each element in the set of matched elements.
.css( propertyName ) - .css( propertyName propertyName,, value ) .css( pr propertyNam opertyNamee, function(index function(index,, value value)) ) .css( map )
0-1
Replace each target element with the set of matched elements.
.offset( coordinates ) - .offset( function(index function(index,, coords coords)) )
Get the current computed height for the first element in the set of matched elements, including padding, border, and optionally margin. Returns an integer (without "px") representation of the value or null if called on an empty set of elements. elements.
Remove all child nodes of the set of matched elements from the DOM.
=
Int
Get the current coordinates of the first element in the set of matched elements, relative to the document.
.before( content [, content content]] ) - .before( function )
.empty()
jQUERY / El
Remove a property for the set of matched elements.
Insert every element in the set of matched elements before the target.
.offset()
Insert content, specified by the parameter, before each element in the set of matched elements.
.detach( [selector [selector]] )
=
.replaceWith()
.attr( attributeName ) - .attr( attributeName attributeName,, value )
.clone()
Int
Insert every element in the set of matched elements after the target.
.insertBefore( target )
Get the value of an attribute for the first element in the set of matched elements.
.before()
Int
Get the current computed width for the first element in the set of matched elements, including padding but not border.
.append( content [, content content]] ) .append( .appen d( function(index function(index,, html html)) )
.appendTo( target )
.innerWidth()
ARRAY / jQ
.removeClass()
Get the current computed height for the first element in the set of matched elements, including padding but not border.
.after( content [, content content]] ) - .after( function(index function(index)) )
.append()
.innerHeight()
=
Remove the set of matched elements from the DOM.
.html( htmlString ) - .html( function(index function(index,, oldhtml oldhtml)) )
Insert content, specified by the parameter, after each element in the set of matched elements.
a
jQ
.hasClass( className ) Determine whether whether any of the matched elements are assigned the given class.
Str
★
.height()
Int
Get the current computed height for the first element in the set of matched elements.
NEW OR CHANGED IN jQUERY 1.7 / f(x)
.toggleClass()
=
FUNCTION /
jQ
Add or remove one or more classes from each element in the set of matched elements, depending on either the class's presence or the value of the switch argument.
.height( value ) .height( value .height( function(index function(index,, height ) )
.innerHeight()
=
Int
=
ARRAY / jQ
=
jQUERY / El
=
ELEMENT /
.die()
=
jQ
Int
Get the current computed width for the first element in the set of matched elements.
Bind an event handler to the "error" JavaScript event.
Get the current computed width for the first element in the set of matched elements, including padding but not border.
.offset()
❉
.blur()
.change()
jQ
jQ
.delegate()
.scrollTop()
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.
Int
.delegate( selector selector,, eventType eventType,, handler ) .delegate( selector selector,, eventType eventType,, eventData eventData,, handler ) .delegate( .delega te( selector selector,, even events ts )
el
jQ
el
event.type
Str
Describes the nature of the event. 0-1
event.which
N
For key or button events, this attribute indicates the specific button or key that was pressed. 0-1
.focus()
jQ
Bind an event handler to the "focus" JavaScript event, or trigger that event on an element 0-1
.focus( handler(eventObject handler(eventObject)) ) .focus( [eventData [ eventData], ], handler(eventObject handler(eventObject)) )
Str
Bind an event handler to the "focusin" event.
N
.focusout()
N
.focusout( handler(eventObject handler(eventObject)) ) .focusout( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.hover() u
If this method is called, the default action of the event will not be triggered.
event.relatedTarget
jQ
Bind an event handler to the "focusout" JavaScript event.
The mouse position relative to the top edge of the document.
event.preventDefault()
jQ
.focusin( handler(eventObject handler(eventObject)) ) .focusin( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
The mouse position relative to the left edge of the document.
event.pageY
jQ
N
The difference in milliseconds between the time the browser created the event and January 1, 1970.
The namespace specified when the event was triggered.
.dblclick( handler(eventObject handler(eventObject)) ) .dblclick( [eventData], handler(eventObject handler(eventObject)) )
.scrollLeft( value .scrollLeft( value )
Obj
Prevents other event handlers from being called.
.focusin() event.namespace
Bind an event handler to the "dblclick" JavaScript event, or trigger that event on an element. Int
STRING
Returns whether event.stopPropagation() was ever called on this event object.
event.pageX
Get the current horizontal position of the scroll bar for the first element in the set of matched elements.
.scrollTop( value .scrollTop( value )
event.isImmediatePropagationStopped()
event.isPropagationStopped()
.click( handler(eventObject handler(eventObject)) ) .click( [eventData], handler(eventObject handler(eventObject)) )
.dblclick()
.removeClass( [className [className]] ) .removeClass(function(index function(index,, class class)) )
event.result
event.timeStamp
Returnswhether event.stopImm event.stopImmediatePropag ediatePropagation() ation()was ever called on this event object.
Bind an event handler to the "click" JavaScript event, or trigger that event on an element.
Remove a single class, multiple classes, or all classes from each element in the set of matched elements.
Get the current vertical position of the scroll bar for the first element in the set of matched elements.
jQ
.change( handler(eventObject handler(eventObject)) ) .change( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.click()
=
Any
The element where the currently-called jQuery event handler was attached.
event.isDefaultPrevented()
Bind an event handler to the "change" JavaScript JavaScript event, or trigger that event on an element.
Obj
NUMBER / Str
event.target
Returns whether event.preventDefault() was ever called on this event object.
.blur( handler(eventObject handler(eventObject)) ) .blur( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
Get the current coordinates of the first element in the set of matched elements, relative to the offset parent.
.scrollLeft()
jQ
Bind an event handler to the "blur" JavaScript event, or trigger that event on an element.
Int
=
jQ
The optional data passed to jQuery.fn.bind when the current executing handler was bound.
★ event.delegateTarget
Int
Get the current computed width for the first element in the set of matched elements, including padding and border.
.removeClass()
jQ
.bind( eventType [, eventData eventData], ], handler(eventObject handler(eventObject)) ) .bind( eventType [, eventData eventData], ], preventBubble ) .bind( events )
Get the current computed height for the first element in the set of matched elements, including padding, border, and optionally margin. Returns an integer (without "px") representation of the value or null if called on an empty set of elements.
.position()
.bind()
/ NUM
The DOM element that initiated the event.
Attach a handler to an event for the elements.
.offset( coordinates ) - .offset( function(index function(index,, coords coords)) )
.outerWidth( [includeMargin [includeMargin]] )
EVENTS
OBJECT
Prevents the event from bubbling up the DOM tree, preventing any parent handlers from being notified of the event.
The current DOM element within the event bubbling phase.
event.data Int
Get the current coordinates of the first element in the set of matched elements, relative to the document.
.outerHeight( [includeMargin [includeMargin]] )
event.currentTarget
=
event.stopPropagation()
.error( handler(eventObject handler(eventObject)) ) .error( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
Int
Obj
event.stopImmediatePropagation() jQ
.width( value .width( value ) - .width( function(index function(index,, width width)) )
.innerWidth()
BOOLEAN /
The last value returned by an event handler that was triggered by this event, unless the value was undefined.
.die( eventType [, handler handler]] ) .die( eventTypes )
.error() .width()
0-1
Remove all event handlers previously attached using .live() from the elements.
.toggleClass( className ) .toggleClass( className className,, switch )
Get the current computed height for the first element in the set of matched elements, including padding but not border.
a
el
Bind two handlers to the matched elements, to be executed when the mouse pointer enters and leaves the elements. .hover( handlerIn(eventObject handlerIn(eventObject)) .handlerOut(eventObject .handlerOut( eventObject)) ) .hover( handlerInOut( handlerInOut(ee ventObject ventObject)) )
jQ
★
.keydown()
jQ
=
NEW OR CHANGED IN jQUERY 1.7 / f(x)
.mouseout()
=
FUNCTION /
jQ
a
=
ARRAY / jQ
=
jQUERY / El
=
ELEMENT /
.scroll()
Bind an event handler to t he "keydown" JavaScript event, or trigger that event on an element.
Bind an event handler to the "mouseout" JavaScript JavaScript event, or trigger that event on an element.
Bind an event handler to the "scroll" JavaScript event, or trigger that event on an element.
.keydown( handler(eventObject handler(eventObject)) ) .keydown( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.mouseout( handler(eventObject handler(eventObject)) ) .mouseout( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.scroll( handler(eventObject handler(eventObject)) ) .scroll( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.keypress()
jQ
.mouseover()
Bind an event handler to t he "keypress" JavaScript event, or trigger that event on an element.
Get the current computed width for the first element in the set of matched elements.
.keypress( handler(eventObject handler(eventObject)) ) .keypress( [eventData [eventData], ], handler handler((eventObject eventObject)) )
.mouseover( handler(eventObject handler(eventObject)) ) .mouseover( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.keyup()
jQ
.mouseup()
Bind an event handler to t he "keyup" JavaScript event, or trigger that event on an element.
Bind an event handler to the "mouseup" JavaScript JavaScript event, or trigger that event on an element.
.keyup( handler(eventObject handler(eventObject)) ) .keyup( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.mouseup( handler(eventObject handler(eventObject)) ) .mouseup( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.live()
jQ
★ .off()
Attach an event handler for all elements which match the current selector, now and in the future.
Remove an event handler.
.live( events events,, handler ) - .live( events events,, data data,, handler ) .live( events-map )
.off( events [, selector selector]] [, handler handler]] ) .off( events-map [, selector selector]] )
.load()
jQ
Bind an event handler to t he "load" JavaScript event. .load( handler(eventObject handler(eventObject)) ) .load( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.mousedown()
jQ
.mouseleave()
jQ
Bind an event handler to be fired when the mouse leaves an element, or trigger that handler on an element.
.ready( handler )
.mouseleave( handler(eventObject handler(eventObject)) .mouseleave( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
Specify a function to execute when the DOM is fully loaded. jQ
.resize()
Bind an event handler to the "mousemove "mousemove"" JavaScript event, or trigger that event on an element.
Bind an event handler to the "resize" JavaScript event, or trigger that event on an element.
.mousemove(handler(eventObject handler(eventObject)) ) .mousemove( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.resize( handler(eventObject handler(eventObject)) ) .resize( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
=
OBJECT
/ NUM
=
NUMBER / Str
=
.undelegate()
STRING
jQ
.undelegate( selector selector,, eventType ) .undelegate( selector selector,, eventType eventType,, handler ) .undelegate( selector selector,, events ) .undelegate( .undel egate( namespace )
.unload()
jQ
Bind an event handler to the "unload" JavaScript event. .unload( handler(eventObject handler(eventObject)) ) .unload( [eventData [eventData], ], handler(eventObject handler(eventObject)) ) jQ ❉
.animate()
.toggle()
jQ
Bind two or more handlers to the matched elements, to be executed on alternate clicks.
jQ
jQ
EFFECTS jQ
Perform a custom animation of a set of CSS properties.
jQ
.animate( properties [, duration duration]] [, easing easing]] [, complete complete]] ) .animate( properties properties,, options )
.clearQueue( [queueName] )
handler(eventObject), handler(eventObject ), handler(eventObject handler(eventObject)) [, handler(eventObject handler( eventObject)] )]
jQ
Remove from the queue all items that have not yet been run. jQ
.delay( duration [, queueName] )
jQ
Set a timer to delay execution of subsequent items in the queue.
.trigger( eventType eventType,, extraParameters extraParameters)) .trigger( event )
.dequeue( [queueName] )
jQ
Execute the next function on the queue for the matched elements.
.triggerHandler()
.one( events [, data data], ], handler ) .one( events [, selector selector]] [, data data], ], handler ) .one( events-map [, selector selector]] [, data data]] )
jQuery.proxy( function,, context ) jQuery.proxy(function jQuery.proxy(context jQuery.proxy( context,, name )
jQ
.submit( handler(eventObject handler(eventObject)) ) .submit( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.on( events [, selector selector]] [, data data], ], handler ) .on( events-map [, selector selector]] [, data data]] )
Takes a function and returns a new one that will always have a particular context.
.mousemove()
.submit()
.trigger()
.mouseenter( handler(eventObject handler(eventObject)) ) .mouseenter( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
Obj
Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements.
Bind an event handler to the "submit" JavaScript event, or trigger that event on an element.
Execute all handlers and behaviors attached to the matched elements for the given event type.
jQuery.proxy()
BOOLEAN /
jQ
Attach a handler to an event for the elements. The handler is executed at most once per element.
Bind an event handler to be fired when the mouse enters an element, or trigger that handler on an element.
jQ
.select( handler(eventObject handler(eventObject)) ) .select( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
Bind an event handler to the "click" JavaScript event, or trigger that event on an element.
.one()
.mousedown( handler(eventObject handler(eventObject)) ) .mousedown( [eventData [eventData], ], handler(eventObject handler(eventObject)) )
.select()
=
Bind an event handler to the "select" JavaScript event, or trigger that event on an element.
jQ
Bind an event handler to the "mousedown" JavaScript JavaScript event, or trigger that event on an element.
.mouseenter()
★ .on()
jQ
0-1
jQ
.fadeIn()
Execute all handlers attached to an element for an event.
jQ
jQ
Display the matched elements by fading them to opaque.
.triggerHandler( eventType eventType,, extraParameters extraParameters))
.fadeIn( [duration [duration]] [, callback ] ) .fadeIn( [duration [duration]] [, easing easing]] [, callback ] )
.unbind()
jQ
.fadeOut()
Remove a previously-attached event handler from the elements.
jQ
Hide the matched elements by fading them to transparent.
.unbind( [eventType [eventType]] [, handler(eventObject handler(eventObject)] )] ) .unbind( eventType eventType,, false )
.fadeOut( [duration [duration]] [, callback ] ) .fadeOut( [duration [duration]] [, easing easing]] [, callback ] )
jQ
.undelegate()
jQ
Remove a handler from the event for all elements which match the current selector, based upon a specific set of root elements. .undelegate( selector selector,, eventType ) .undelegate( selector selector,, eventType eventType,, handler ) .undelegate( selector selector,, events ) .undelegate( .undel egate( namespace )
jQ
.fadeTo()
jQ
Adjust the opacity of the matched elements. .fadeTo( duration duration,, opacity opacity [, [, callback ] ) .fadeTo( duration duration,, opacity opacity [, [, easing easing]] [, callback ] )
.fadeToggle( [duration] [, easing] [, callback] )
jQ
★
jQuery.fx.interval
N
The rate (in milliseconds) at which animations fire.
jQuery.fx.off
NEW OR CHANGED IN jQUERY 1.7 / f(x)
=
jQ
jqXHR
Perform an asynchronous HTTP (Ajax) request.
.ajaxComplete()
jQ
Register a handler to be called when Ajax requests complete. This is an Ajax Event.
.hide( duration [, callback ] ) .hide( [duration [duration]] [, easing easing]] [, callback ] ) a()
Show the queue of functions to be executed on the matchedelements.
jQ
.ajaxError()
=
jQUERY / El
=
ELEMENT /
jQ
jQ
jQuery.ajaxPrefilter()
u
jQ
.ajaxSend()
.slideDown( [duration [duration]] [, callback ] ) .slideDown( [duration [duration]] [, easing easing]] [, callback ] )
Attach a function to be executed before an Ajax request is sent. This is an Ajax Event.
jQ
Encode a set of form elements as a string for submission.
.slideUp()
jQ
Hide the matched elements with a sliding motion.
.ajaxStop( handler() )
.slideUp( [duration [duration]] [, callback ] ) .slideUp( [duration [duration]] [, easing easing]] [, callback ] )
.ajaxSuccess()
Obj
jQ
Execute the next function on the queue for the matched elements. Obj
jQuery.each( collection collection,, callback(indexInArray callback(indexInArray , valueOfElement)) ) valueOfElement
jqXHR
Obj
jQuery.extend( target [, object1 object1]] [, objectN objectN]] ) jQuery.extend( [ deep deep], ], target target,, object1 [, objectN objectN]] )
jQuery.globalEval( code ) Execute some JavaScript code globally. jQuery.each( collection collection,, callback(indexInArray callback(indexInArray , valueOfElement)) ) valueOfElement Str
jQuery.grep()
a()
Finds the elements of an array which satisfy a filter function. The original array is not affected. a()
jQuery.grep( array , function(elementOfArray function(elementOfArray , indexInArray ) [, invert invert]] )
jQuery.inArray()
UTILITIES
N
jQuery.inArray( value jQuery.inArray( value,, array [, fromIndex fromIndex]] )
jQ
jQuery.boxModel
0-1
Deprecated
jQuery.browser jQuery.get()
0-1
Search for a specified value within an array and return its index (or -1 if not found).
.ajaxSuccess( handler( .ajaxSuccess( handler(event event,, XMLHttpRequest XMLHttpRequest,, ajaxOptions)) ) ajaxOptions jQ
jQuery.contains( container, contained )
Merge the contents of two or more objects together into the first object.
jQ
Attach a function to be executed whenever whenever an Ajax request completes successfully. This is an Ajax Event.
.stop( [clearQueue [clearQueue]] [, jumpToEnd [, jumpToEnd]] ) .stop( [queue [queue]] [, clearQueue clearQueue]] [, jumpToEnd [, jumpToEnd]] )
STRING
jQuery.extend()
Encode a set of form elements as an array of names and values.
❉
Stop the currently-running animation on the matched elements.
.toggle()
Str
jQ
.serializeArray()
=
A generic iterator function, which can be used to seamlessly iterate over both objects and arrays.
Register a handler to be called when all Ajax requests have completed. This is an Ajax Event. jQ
NUMBER / Str
jQuery.each()
Load data from the server using a HTTP POST request.
Set default values for future Ajax requests.
.ajaxStart( handler() )
=
.dequeue( [queueName] ) jqXHR
Create a serialized representation of an array or object, suitable for use in a URL query string or Ajax request.
.serialize()
Register a handler to be called when the first Ajax request begins. This is an Ajax Event.
/ NUM
jQuery.data( element , key key ,, value ) jQuery.data( element element,, key key )) jQuery.data( element )
Load data from the server and place the returned HTML into the matched element.
jQuery.ajaxSetup( options )
.slideToggle( [duration [duration]] [, callback ] ) .slideToggle( [duration [duration]] [, easing easing]] [, callback ] )
★ .stop()
jqXHR
Load a JavaScript file from the server using a GET HTTP request, then execute it.
jQ
Display or hide the matched elements with a sliding motion.
OBJECT
jQuery.getScript()
jQuery.post( url [, data data]] [, success(data success(data,, textStatus textStatus,, jqXHR )] )] [, dataType dataType]] )
.ajaxSend(handler(event handler( event,, jqXHR , ajaxOptions ajaxOptions)) )
=
Store arbitrary data associated with the specified element. Returns the value that was set.
jQuery.post()
Display the matched elements with a sliding motion.
Obj
jQuery.data()
jQuery.param( obj ) jQuery.param( obj obj,, traditional )
jQuery.ajaxPrefilter( Query.ajaxPrefilter( [ dataTypes dataTypes]] , handler(options handler(options,, originalOptions,, jqXHR ) ) originalOptions
BOOLEAN /
Check to see if a DOM element is within another DOM element.
.load( url [, data data]] [, complete(responseText complete(responseText,, textStatus,, XMLHttpRequest)] ) textStatus
Handle custom Ajax options or modify existing options before each request is sent and before they are processed by $.ajax().
.show( duration [, callback ] ) .show( [duration [duration]] [, easing easing]] [, callback ] )
.slideToggle()
jqXHR
.ajaxError( handler(event handler(event,, jqXHR , ajaxSettings ajaxSettings,, thrownError)) ) thrownError
Display the matched elements.
.slideDown()
=
jQuery.getJSON( url [, data jQuery.getJSON(url data]] [, success(data success(data,, textStatus,, jqXHR )] textStatus )] )
jQuery.param() .show()
0-1
Load JSON-encoded data from the server using a GET HTTP request.
.load()
Register a handler to be called when Ajax requests complete with an error. This is an Ajax Event.
.queue( [queueName [queueName]] ) .queue( [queueName [queueName]] , newQueue ) .queue( [queueName [queueName]] , callback( next ) )
ARRAY / jQ
jQuery.getScript(url jQuery.getScript( url [, success(data success(data,, textStatus textStatus)] )] )
.ajaxComplete( handler( .ajaxComplete( handler(event event,, XMLHttpRequest XMLHttpRequest,, ajaxOptions)) ) ajaxOptions
.queue()
=
jQuery.getJSON()
jQuery.ajax( url [, settings settings]] ) jQuery.ajax( settings )
Hide the matched elements.
a
FUNCTION /
❉ AJAX
jQuery.ajax() 0-1
Globally disable all animations.
.hide()
=
jqXHR
Load data from the server using a HTTP GET request.
.toggle( [duration [duration]] [, callback ] ) .toggle( [duration [duration]] [, easing easing]] [, callback ] ) .toggle( showOrHide )
.clearQueue( [queueName] )
jQuery.get( url [, data data]] [, success(data success(data,, textStatus textStatus,, jqXHR )] )] [, dataType dataType]] )
Remove from the queue all items that have not yet been run.
0-1
Determine whether whether the argument is an array. Map
Deprecated
Display or hide the matched elements.
jQuery.isArray( obj )
jQuery.isEmptyObject( object )
0-1
Check to see if an object is empty (contains no properties). jQ
jQuery.isFunction( object ) Determine if the argument passed is a Javascript function object.
0-1
★
★ jQuery.isNumeric( object )
0-1
Determines whether whether its argument is a number.
jQuery.isPlainObject( object )
0-1
Check to see if an object is a plain object (created using "{}" or "new Object").
jQuery.isWindow( object )
0-1
=
NEW OR CHANGED IN jQUERY 1.7 / f(x)
=
.queue()
a()
Show the queue of functions to be executed on the matched elements.
jQ
.queue( [queueName [queueName]] ) .queue( [queueName [queueName]] , newQueue ) .queue( [queueName [queueName]] , callback( next ) )
jQuery.removeData()
=
ARRAY / jQ
=
jQUERY / El
=
ELEMENT /
★ callbacks.fired()
jQ
0-1
=
0-1
u
jQuery.makeArray( object )
jQuery.map()
a()
jQuery.map( array , callback(elementOfArray callback(elementOfArray , indexInArray ) ) jQuery.map( arrayOrObject arrayOrObject,, callback( value callback( value,, indexOrKey )) ) indexOrKey
Determine the internal JavaScript [[Class]] of an object.
jQuery.unique( array array )) a()
jQuery.noop()
jQuery.now()
jQuery.parseXML( data )
Str
XMLdoc
a()
jQuery.queue() Takes a function and returns a new one that will always have a particular context.
u
0-1
u
Num
jQuery.noConflict( [removeAll] )
Obj
.size()
Num
★ jQuery.Callbacks( flag )
DATA & MISCELLANEOUS
DEFERRED
deferred.always() jQ
deferred.always(alwaysCallbacks deferred.always( alwaysCallbacks[, [, alwaysCallbacks alwaysCallbacks]] )
deferred.done()
data( key key ,, value ), data( key )
deferred.done(doneCallbacks deferred.done( doneCallbacks[, [, doneCallbacks doneCallbacks]] )
★ callbacks.add( callbacks )
Execute the next function on the queue for the matched element. jQuery.dequeue(element jQuery.dequeue( element [, queueName queueName]] )
deferred.fail()
jQuery.hasData( element )
Add handlers to be called when the Deferred object is rejected.
u
jQ
0-1
★ callbacks.empty()
deferred.isRejected() u
Remove all of the callbacks from a list. a()
★ callbacks.fire( arguments )
u
Call all of the callbacks with the given arguments
jQ
deferred.isResolved()
.removeData( [name [name]] ), .removeData( [list [list]] )
Determine whether a Deferred object has been resolved.
.each() .each( function(index function(index Element Element)) )
jQ
0-1
Determine whether a Deferred object has been rejected.
Remove a previously-stored piece of data.
Remove a previously-stored piece of data.
def
deferred.fail( failCallbacks [, failCallbacks failCallbacks]] )
Determine whether whether an element has any jQuery data associated with it.
★ .removeData()
def
Add handlers to be called when the Deferred object is resolved.
jQuery.dequeue()
Add a callback or a collection of callbacks to a callback list.
def
Add handlers to be called when the Deferred object is either resolved or rejected.
A multi-purpose callbacks list object that provides a powerful way to manage callback lists. u
a()
Retrieve all the DOM elements contained in the jQuery set, as an array.
Remove a callback or a collection of callbacks from a callback list.
Disable a callback list from doing anything more.
jQ
el a()
Relinquish jQuery's control of the $ variable.
Store arbitrary data associated with the matched elements.
f(x)
jQuery.proxy( function function,, context ) jQuery.proxy( context context,, name )
jQ
Search for a given element from among the matched elements.
.toArray()
.data()
CALLBACKS OBJECT
★ callbacks.disable() Takes a function and returns a new one that will always have a particular context.
.get( [index] )
❉
Parses a string into an XML document.
jQuery.proxy()
.each()
STRING
Determine if the callbacks list has been locked.
callback )) ★ callbacks.remove( callback
Obj
Takes a well-formed JSON string and returns the resulting JavaScript object.
=
.index( selector ), .index( element )
Sorts an array of DOM elements, in place, with the duplicates removed. removed. Note that this only works on arrays of DOM elements, not strings or numbers.
❉
Return a number representing the current time.
jQuery.parseJSON( json jQuery.parseJSON( json )
★ callbacks.locked()
f(x)
N
0-1
Lock a callback list in its current state.
❉
An empty function.
NUMBER / Str
Return the number of elements in the jQuery object.
jQuery.type( obj )
Merge the contents of two arrays together into the first array.
=
.each( function(index function(index,, Element Element)) )
Determine whether whether a supplied callback is in a list.
★ callbacks.lock() Str
Remove the whitespace from the beginning and end of a string.
Translate all items in an array or object to new array of items.
jQuery.merge( first first,, second )
obj
a()
jQuery.trim( str )
/ NUM
.index
A collection of properties that represent the presence of different browser features or bugs.
Convert an array-like object into a true JavaScript array.
OBJECT
Retrieve the DOM elements matched by the jQuery object.
Call all callbacks in a list with the given context and arguments.
callback )) ★ callbacks.has( callback jQuery.support
=
callbacks.fireWith( callbacks.fireWi th( [context context]] [, args args]] )
0-1
Check to see if a DOM node is within an XML document (or is an XML document).
Obj
.each( function(index function(index,, Element Element)) )
jQuery.removeData(element jQuery.removeData( element [, name name]] )
jQuery.isXMLDoc( object )
BOOLEAN /
Remove a previously-stored piece of data.
Determine if the callbacks have already been called at least once.
★ callbacks.fireWith()
Remove a previously-stored piece of data
Determine whether the argument is a window.
a
FUNCTION /
deferred.notify( args ) Call the progressCallbacks on a Deferred object with the given args.
0-1
0-1
★
deferred.notifyWith()
def
Call the progressCallbacks on a Deferred object with the given context and args.
=
NEW OR CHANGED IN jQUERY 1.7 / f(x)
.promise()
=
FUNCTION /
promise
Return a Promise object to observe when all actions of a certain type bound to the collection, queued or not, have finished.
deferred.notifyWith(context deferred.notifyWith( context [, args args]] )
.promise( [type [type]] [, target target]] )
deferred.pipe()
promise
Utility method to filter and/or chain Deferreds.
jQuery.when( deferreds )
promise
ARRAY / jQ
=
jQUERY / El
=
ELEMENT /
0-1
=
BOOLEAN /
New or Changed in jQuery 1.7.1
Obj
=
OBJECT
/ NUM
=
NUMBER / Str
=
STRING
About jQuery
WHAT’S NEW?
THE WRITE LESS, DO MORE, JAVASCRIPT LIBRARY
Aspects of the API that were changed in the corresponding version of jQuery. API changes in jQuery 1.7.0 dealt primarily with the new Event APIs: .on() and .off()
jQuery is a fast and concise JavaScript Library that simplifies HTML document traversing, event handling, animating, and Ajax interactions for rapid web development. jQuery is designed to change the way that you write JavaScript.
Better Support for HTML5 in IE6/7/8
Toggling Animations Work Intuitively
jQuery Official Web Site http://jquery.com Download http://docs.jquery.com/Downloading_jQuery Documentationhttp://docs.jquery.com/Main_Page Documentation http://docs.jquery.com/Main_Page
❉
deferred.progress()
=
jQuery.Callbacks()
Provides a way to execute callback functions based on one or more objects, usually Deferred objects that represent asynchronous events.
deferred.pipe( [doneFilter [doneFilter]] [, failFilter failFilter]] ) deferred.pipe( [doneFilter [doneFilter]] [, failFilter failFilter]] [, progressFilter]] ) progressFilter
a
def
jQuery.Callbacks() callbacks.add() callbacks.disable()
Add handlers to be called when the Deferred object generates progress notifications.
callbacks.empty()
Tutorials http://docs.jquery.com/Tutorials Bug Traker http://bugs.jquery.com/newticket Discussion http://docs.jquery.com/Discussion
callbacks.fire()
deferred.progress(progressCallbacks deferred.progress( progressCallbacks))
callbacks.fired()
deferred.promise()
promise
callbacks.fireWith()
Credits
callbacks.has()
JQUERY 1.7 VISUAL CHEAT SHEET
Return a Deferred's Promise object.
callbacks.lock()
deferred.promise( deferred.promis e( [target target]] )
callbacks.locked()
This jQuery visual cheat sheet is designed by Antonio Lupetti and is distributed for free.
callbacks.remove() callbac ks.remove()
deferred.reject( args )
def
deferred.notify() deferred.pipe() deferred.progress()
deferred.rejectWith()
def
deferred.state()
Reject a Deferred object and call any failCallbacks with the given context and args.
deferred.then()
deferred.rejectWith(context deferred.rejectWith( context [, args args]] )
.is()
event.delegateTarget jQuery.isNumeric()
deferred.resolve( args )
def
.off() .on()
Resolve a Deferred object and call any doneCallbacks with the given args.
.removeAttr() .removeData()
deferred.resolveWith()
def
Resolve a Deferred object and call any doneCallbacks with the given args. deferred.resolveWith(context deferred.resolveWith( context [, args args]] )
deferred.state()
Str
Determine the current state of a Deferred object.
deferred.then() Add handlers to be called when the Deferred object is resolved or rejected. deferred.then( doneCallbacks doneCallbacks,, failCallbacks ) deferred.then( doneCallbacks doneCallbacks,, failCallbacks [, progressCallbacks] )
Update as of december 2011, jQuery current release v 1.7.1
deferred.notifyWith()
Reject a Deferred object and call any failCallbacks with the given args.
def
.stop()
My Blog http://woorkup.com Twitter @woork - http://twitter.com/woork Facebook http://facebook.com/antoniolupetti Google+ https://plus.google.com/u/0/112930363515083491757