SlideShare uma empresa Scribd logo
1 de 65
JQUERY EXAMPLE 
http://www.youtube.com/kamleshutube
SELECTORS / 1. BASIC 
All Selector(“*”) Selects all elements. 
Class Selector (“.class”) Matches all elements with the given 
name. 
Element Selector (“element”) Selects all elements with the given tag 
name 
ID Selector (“#id”) Selects a single element with the given id 
attribute. 
Multiple Selector (“selector1, 
selector2, selectorN”) 
Selects the combined results of all the 
specified selectors.
http://www.youtube.com/watch?v=jWSodFG2XMg
SELECTORS / 2. HIERARCHY 
Child Selector (“parent > child”) Selects all direct child elements 
specified by "child" of elements 
specified by "parent". 
Descendant Selector (“ancestor 
descendant”) 
Selects all elements that are 
descendants of a given ancestor. 
Next Adjacent 
Selector (“prev + next”) 
Selects all next elements matching 
"next" 
that are immediately preceded by a 
sibling 
"prev". 
Next Siblings Selector (“prev ~ 
siblings”) 
Selects all sibling elements that follow 
after the "prev" element, have the same 
parent, and match the filtering 
"siblings" selector.
http://www.youtube.com/watch?v=ATN8KoTONts
SELECTORS / 3. BASIC FILTER 
:eq() Selector Select the element at index n within the 
matched set. 
:even Selector Selects even elements, zero-indexed 
:first Selector Selects the first matched element. 
:gt() Selector Select all elements at an index greater than 
index within the matched set. 
:header Selector Selects all elements that are headers, like 
h1, h2, h3 and so on. 
:last Selector Selects the last matched element. 
:lt() Selector Select all elements at an index less than 
index within the matched set. 
:not() Selector Selects all elements that do not match the 
given selector. 
:odd Selector Selects odd elements, zero-indexed. See 
also even.
http://www.youtube.com/watch?v=pUXxG1oCgkE
SELECTORS / 4. CONTENT 
FILTER 
:contains() Selector Select all elements that contain the specified 
text. 
:has() Selector Selects elements which contain at least one 
element that matches the specified selector. 
:parent Selector Select all elements that are the parent of 
another element, including text nodes.
http://www.youtube.com/watch?v=1xu0clYY7-Y
SELECTORS / 5. ATTRIBUTE 
[attribute|=value] 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 (-). 
[attribute*=value] Selects elements that have the specified attribute with a value 
containing the a given substring. 
[attribute~=value] Selects elements that have the specified attribute with a value 
containing a given word, delimited by spaces. 
[attribute$=value] Selects elements that have the specified attribute with a value 
ending exactly with a given string. 
[attribute=value] Selects all elements that are matched specified value 
[attribute!=value] Select elements that either don't have the specified attribute, 
or do have the specified attribute but not with a certain value. 
[attribute^=value] Selects elements that have the specified attribute with a value 
beginning exactly with a given string. 
[attribute] Selects elements that have the specified 
attribute, with any value. 
[attribute=value] 
[attribute2=value2] 
Matches elements that match all of the specified attribute 
filters.
http://www.youtube.com/watch?v=tdujPn8HNr4
SELECTORS / 6. CHILD 
FILTER 
:first-child Selector Selects all elements that are the first child 
of their parent. 
:last-child Selector Selects all elements that are the last child 
of their parent. 
:nth-child Selector Selects all elements that are the nth-child 
of their parent. 
:only-child Selector Selects all elements that are the only child 
of their parent.
http://www.youtube.com/watch?v=11tKyyhBBzY
SELECTORS / 7. FORM 
(contd.) 
:button Selector Selects all button elements and elements of 
type button. 
:checkbox Selector Selects all elements of type checkbox. 
:checked Selector Matches all elements that are checked. 
:disabled Selector Selects all elements that are disabled. 
:enabled Selector Selects all elements that are enabled. 
:file Selector Selects all elements of type file. 
:image Selector Selects all elements of type image.
SELECTORS / 7. FORM 
:input Selector Selects all input, textarea, select and 
button elements. 
:password Selector Selects all elements of type password. 
:radio Selector Selects all elements of type radio. 
:reset Selector Selects all elements of type reset. 
selected Selector Selects all elements that are selected. 
:submit Selector Selects all elements of type submit. 
:text Selector Selects all elements of type text.
http://www.youtube.com/watch?v=9snkUllPv9A
EVENTS / MOUSE EVENTS (contd.) .click( handler(eventObject) ) Bind an event handler to the "click" JavaScript 
event, or trigger that event on an element. 
.dblclick( handler(eventObject) ) Bind an event handler to the "dblclick" 
JavaScript event, or trigger that event on an 
element. 
.focusout( handler(eventObject) ) Bind an event handler to the "focusout" 
JavaScript event. 
.hover( handler(eventObject) ) Bind a single handler to the matched 
elements, to be executed when the mouse 
pointer enters or leaves the elements. 
.mousedown( handler(eventObject) 
) 
Bind an event handler to the "mousedown" 
JavaScript event, or trigger that event on an 
element. 
.mouseenter( handler(eventObject) 
) 
Bind an event handler to be fired when the 
mouse enters an element, or trigger that 
handler on an element.
EVENTS / MOUSE EVENTS 
. 
mouseleave( handler(eventObje 
ct) ) 
Bind an event handler to be fired when the 
mouse leaves an element, or trigger that handler 
on an element. 
. 
mousemove( handler(eventObje 
ct) ) 
Bind an event handler to the "mousemove" 
JavaScript event, or trigger that event on an 
element. 
.mouseout( handler(eventObject) 
) 
Bind an event handler to the "mouseout" 
JavaScript event, or trigger that event on an 
element. 
. 
mouseover( handler(eventObject 
) ) 
Bind an event handler to the "mouseover" 
JavaScript event, or trigger that event on an 
element. 
. 
mouseup( handler(eventObject) 
) 
Bind an event handler to the "mouseup" 
JavaScript event, or trigger that event on an 
element.
http://www.youtube.com/watch?v=HDMIUaoiiMk
EVENTS - FORM EVENTS 
.blur( handler(eventObject) ) Bind an event handler to the "blur" JavaScript 
event, or trigger that event on an element. 
.focus( handler(eventObject) ) Bind an event handler to the "focus" 
JavaScript event, or trigger that event on an 
element. 
.change( handler(eventObject) ) Bind an event handler to the "change“ 
JavaScript event, or trigger that event on an 
element. 
.select( handler(eventObject) ) Bind an event handler to the "select" 
JavaScript event, or trigger that event on an 
element. 
.submit( handler(eventObject) ) Bind an event handler to the "submit" 
JavaScript event, or trigger that event on an 
element.
http://www.youtube.com/watch?v=Ltb0TUO8qsw
EVENTS - EVENT OBJECT 
.pageX The mouse position relative to the left edge of the 
document 
.pageY The mouse position relative to the top edge of the 
document. 
.type Describes the nature of the event. 
.target The DOM element that initiated the event. 
.preventDefault() If this method is called, the default action 
of the event will not be triggered. 
.isDefaultPrevented() Returns whether event.preventDefault() was ever 
called on this event object. 
.which For key or button events, this attribute 
indicates the specific button or key that was 
pressed
http://www.youtube.com/watch?v=4PvYg4D2R1w
ATTRIBUTES - CLASS 
.addClass( class ) Adds the specified class(es) to each of the set of 
matched elements. 
.removeClass( class ) Remove a single class, multiple classes, or all 
classes from each element in the set of matched 
elements. 
.hasClass( class ) Determine whether any of the matched elements are 
assigned the given class. 
.toggleClass( class, switch ) 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.
http://www.youtube.com/watch?v=CPJpIpm7qCs
CSS - POSITIONING 
.scrollLeft() Get the current horizontal position of the scroll bar 
for the first element in the set of matched elements. 
.scrollLeft( value ) Set the current horizontal position of the scroll bar for 
each of the set of matched elements. 
.offset() Get the current coordinates of the first element in the set 
of matched elements, relative to the document. 
.offset( coordinates ) Set the current coordinates of every element in the 
set of matched elements, relative to the document. 
.position() Get the current coordinates of the first element in the set 
of matched elements, relative to the offset parent. 
.scrollTop() Get the current vertical position of the scroll bar for 
the first element in the set of matched elements. 
.scrollTop( value ) Set the current vertical position of the scroll bar for 
each of the set of matched elements.
http://www.youtube.com/watch?v=zWX0ZzYrS_4
TRAVERSING -TREE 
TRAVERSAL (cont.) 
.children( [ selector ] ) Get the children of each element in the set of 
matched elements, optionally filtered by a 
selector 
.closest( selector ) Get the first ancestor element that matches 
the selector, beginning at the current 
element and progressing up through the 
DOM tree. 
.find( selector ) Get the descendants of each element in the 
current set of matched elements, filtered by a 
selector. 
.next( [ selector ] ) Get the immediately following sibling of each 
element in the set of matched elements, 
optionally filtered by a selector. 
.nextAll( [ selector ] ) Get all following siblings of each element in 
the set of matched elements, optionally 
filtered by a selector.
TRAVERSING -TREE 
TRAVERSAL (cont.) 
.nextUntil( [ selector ] ) Get all following siblings of each element 
up 
to but not including the element matched 
by 
the selector. 
.parent( [ selector ] ) Get the parent of each element in the 
current 
set of matched elements, optionally filtered 
by a selector. 
.parents( [ selector ] ) Get the ancestors of each element in the 
current set of matched elements, optionally 
filtered by a selector. 
.prev( [ selector ] ) Get the immediately preceding sibling of 
each 
element in the set of matched elements, 
optionally filtered by a selector.
TRAVERSING -TREE 
TRAVERSAL 
.prevAll( [ selector ] ) Get all preceding siblings of each element in 
the set of matched elements, optionally filtered 
by a selector. 
.prevUntil( [ selector ] ) Get the ancestors of each element in the 
current set of matched elements, optionally 
filtered by a selector. 
.siblings( [ selector ] ) Get the siblings of each element in the set of 
matched elements, optionally filtered by a 
selector.
http://www.youtube.com/watch?v=1M4hThjV1vs 
http://www.youtube.com/watch?v=_z74QVjOOiA
TRAVERSING - FILTERING 
.eq( index ) Reduce the set of matched elements to the one at 
the specified index. 
.filter( selector ) Reduce the set of matched elements to those that 
match the selector or pass the function's test. 
.is( selector ) Check the current matched set of elements 
against a selector and return true if at least one 
of these elements matches the selector 
.not() Remove elements from the set of matched 
elements. 
.slice( start, [ end ] ) Reduce the set of matched elements to a subset 
specified by a range of indices. 
.map( callback(index, domEl) ) Pass each element in the current matched set 
through a function, producing a new jQuery 
object containing the return values.
http://www.youtube.com/watch?v=z_9IzPfxkrw
TRAVERSING - 
MISCELLANEOUS 
.add( selectors, [ context ] ) Add elements to the set of matched elements 
.andSelf() Add the previous set of elements on the stack to 
the current set. 
.contents() Get the children of each element in the set of 
matched elements, including text nodes. 
.end() End the most recent filtering operation in the 
current chain and return the set of matched 
elements to its previous state.
http://www.youtube.com/watch?v=rU1SNaVs2ic
ATTRIBUTES - ATTR 
.attr( attributeName ) Get the value of an attribute for the 
first element in the set of matched 
elements. 
.attr( attributeName, 
value ) 
Set one or more attributes for the set 
of matched elements. 
.removeAttr() Remove an attribute from each element 
in the set of matched elements.
http://www.youtube.com/watch?v=UvkCRCXHVzI
ATTRIBUTES - HTML 
.html() Get the HTML contents of the first 
element in the set of matched 
elements. 
.html( htmlString ) Set the HTML contents of each 
element 
in the set of matched elements.
http://www.youtube.com/watch?v=JqzA9T3OfNM
ATTRIBUTES - TEXT 
.text() Get the combined text contents of each 
Element in the set of matched 
elements, including their descendants. 
.text( textString ) Set the content of each element in the 
set of matched elements to the 
specified text.
http://www.youtube.com/watch?v=NiQGohUxKiA
ATTRIBUTES - VALUE 
.val() Get the current value of the first element in 
the set of matched elements. 
.val( value ) Set the value of each element in the set of 
matched elements.
http://www.youtube.com/watch?v=o_K6q3QxJ7Y
CSS - CSS 
css( propertyName ) Get the value of a style property for 
the first element in the set of 
matched elements. 
.css( propertyName, 
value) 
Set one or more CSS properties for 
the set of matched elements.
http://www.youtube.com/watch?v=ROewNE8mc_A
CSS - HEIGHT & WIDTH (cont.) 
.height( value ) Set the CSS height of every matched element. 
element in the set of matched 
elements. 
.height() Get the current computed height for the first 
.innerHeight() Get the current computed height for the first. 
element in the set of matched elements, 
including padding but not border 
.innerWidth() Get the current computed width for the first 
element in the set of matched elements, 
including padding but not border. 
.outerHeight() Get the current computed height for the first 
element in the set of matched elements, 
including padding, border, and optionally 
margin. 
.outerWidth() Get the current computed width for the first 
element in the set of matched elements, 
including padding and border.
CSS - HEIGHT & WIDTH 
.width( value ) Set the CSS width of each element in the set of 
matched elements. 
.width() Get the current computed width for the first element in 
the set of matched element
http://www.youtube.com/watch?v=faxfelPFFjc
MANIPULATION - INSIDE 
.append( content ) Insert content, specified by the parameter, to the 
end of each element in the set of matched 
elements. 
.appendTo( target ) Insert every element in the set of matched 
elements to the end of the target. 
.prepend( content ) Insert content, specified by the parameter, to the 
beginning of each element in the set of matched 
elements. 
.prependTo( target ) Insert content, specified by the parameter, to the 
end of each element in the set of matched 
elements.
http://www.youtube.com/watch?v=egkrz9baf9I
MANIPULATION - OUTSIDE 
.after( content ) Insert content, specified by the parameter, after each element 
in the set of matched elements. 
.before( content ) Insert content, specified by the parameter, before each 
element in the set of matched elements. 
.insertAfter( target ) Insert every element in the set of matched elements after the 
target. 
.insertBefore( target ) Insert every element in the set of matched elements before 
the target.
http://www.youtube.com/watch?v=cSBmIJJJ_XA
MANIPULATION - AROUND 
.wrap( wrappingElement ) Wrap an HTML structure around each element in 
the set of matched elements. 
.wrapAll( wrappingElement ) Wrap an HTML structure around all elements in 
the set of matched elements. 
.wrapInner( wrappingElement ) Wrap an HTML structure around the content of 
each element in the set of matched elements.
http://www.youtube.com/watch?v=cSBmIJJJ_XA
MANIPULATION - REPLACING 
.replaceWith( newContent ) Replace each element in the set of matched elements 
with the provided new content. 
.replaceAll() A selector expression indicating which element(s) to 
replace.
http://www.youtube.com/watch?v=WA6G1eVF7Po
EVENTS - HANDLER 
ATTACHMENT 
.bind( eventType, [ eventData ], handler 
(eventObject) ) 
Attach a handler to an event for the 
elements. 
.unbind( eventType, handler 
(eventObject) ) 
Remove a previously-attached event 
handler from the elements. 
.die() Remove all event handlers previously 
attached using .live() from the elements. 
.live( eventType, eventData, handler ) Attach a handler to the event for all 
elements which match the current 
selector, now or in the future. 
.one( eventType, [ eventData ], handler 
(eventObject) ) 
Attach a handler to an event for the 
elements. The handler is executed at 
most once per element.
http://www.youtube.com/watch?v=krpWZ7kIXt8 
http://www.youtube.com/watch?v=Axa7kKbC4Ec 
http://www.youtube.com/watch?v=Axa7kKbC4Ec
EFFECTS - BASIC 
.hide( duration, [ callback ] ) 
Hide the matched elements. 
.show( duration, [ callback ] ) 
Display the matched elements.
http://www.youtube.com/watch?v=674_VLph2vU
EFFECTS - SLIDING 
.slideDown( [ duration ], [ callback ] ) 
Display the matched elements with a sliding motion. 
.slideToggle( [ duration ], [ callback ] ) 
Display or hide the matched elements with a sliding motion. 
.slideUp( [ duration ], [ callback ] ) 
Hide the matched elements with a sliding motion.
http://www.youtube.com/watch?v=2UQrqp4HKjw
EFFECTS - FADING 
.fadeIn( [ duration ], [ callback ] ) 
Display the matched elements by fading them to opaque. 
.fadeOut( [ duration ], [ callback ] ) 
Hide the matched elements by fading them to transparent. 
.fadeTo( duration, opacity, [ callback ] ) 
Adjust the opacity of the matched elements.
http://www.youtube.com/watch?v=g2c44rYWfmI
Thank You

Mais conteúdo relacionado

Mais procurados

Event Handling in java
Event Handling in javaEvent Handling in java
Event Handling in javaGoogle
 
Event Handling in Java
Event Handling in JavaEvent Handling in Java
Event Handling in JavaAyesha Kanwal
 
Graphical User Interface (GUI) - 2
Graphical User Interface (GUI) - 2Graphical User Interface (GUI) - 2
Graphical User Interface (GUI) - 2PRN USM
 
Advance Java Programming(CM5I) Event handling
Advance Java Programming(CM5I) Event handlingAdvance Java Programming(CM5I) Event handling
Advance Java Programming(CM5I) Event handlingPayal Dungarwal
 
J Query Introduction And JQuery Selectors
J Query Introduction And JQuery SelectorsJ Query Introduction And JQuery Selectors
J Query Introduction And JQuery SelectorsAnand Kumar Rajana
 
tL20 event handling
tL20 event handlingtL20 event handling
tL20 event handlingteach4uin
 
Event handling63
Event handling63Event handling63
Event handling63myrajendra
 
Java Event Handling
Java Event HandlingJava Event Handling
Java Event HandlingShraddha
 
Web Design & Development - Session 6
Web Design & Development - Session 6Web Design & Development - Session 6
Web Design & Development - Session 6Shahrzad Peyman
 
Event handling
Event handlingEvent handling
Event handlingswapnac12
 
Ajp notes-chapter-03
Ajp notes-chapter-03Ajp notes-chapter-03
Ajp notes-chapter-03Ankit Dubey
 
Unit-3 event handling
Unit-3 event handlingUnit-3 event handling
Unit-3 event handlingAmol Gaikwad
 
JAVA GUI PART III
JAVA GUI PART IIIJAVA GUI PART III
JAVA GUI PART IIIOXUS 20
 
Advance Java Programming (CM5I) 2.Swing
Advance Java Programming (CM5I) 2.SwingAdvance Java Programming (CM5I) 2.Swing
Advance Java Programming (CM5I) 2.SwingPayal Dungarwal
 
Programação GUI com jRuby
Programação GUI com jRubyProgramação GUI com jRuby
Programação GUI com jRubyFrevo on Rails
 

Mais procurados (17)

Event handling
Event handlingEvent handling
Event handling
 
Event Handling in java
Event Handling in javaEvent Handling in java
Event Handling in java
 
Event Handling in Java
Event Handling in JavaEvent Handling in Java
Event Handling in Java
 
Graphical User Interface (GUI) - 2
Graphical User Interface (GUI) - 2Graphical User Interface (GUI) - 2
Graphical User Interface (GUI) - 2
 
Advance Java Programming(CM5I) Event handling
Advance Java Programming(CM5I) Event handlingAdvance Java Programming(CM5I) Event handling
Advance Java Programming(CM5I) Event handling
 
J Query Introduction And JQuery Selectors
J Query Introduction And JQuery SelectorsJ Query Introduction And JQuery Selectors
J Query Introduction And JQuery Selectors
 
tL20 event handling
tL20 event handlingtL20 event handling
tL20 event handling
 
Event handling in Java(part 1)
Event handling in Java(part 1)Event handling in Java(part 1)
Event handling in Java(part 1)
 
Event handling63
Event handling63Event handling63
Event handling63
 
Java Event Handling
Java Event HandlingJava Event Handling
Java Event Handling
 
Web Design & Development - Session 6
Web Design & Development - Session 6Web Design & Development - Session 6
Web Design & Development - Session 6
 
Event handling
Event handlingEvent handling
Event handling
 
Ajp notes-chapter-03
Ajp notes-chapter-03Ajp notes-chapter-03
Ajp notes-chapter-03
 
Unit-3 event handling
Unit-3 event handlingUnit-3 event handling
Unit-3 event handling
 
JAVA GUI PART III
JAVA GUI PART IIIJAVA GUI PART III
JAVA GUI PART III
 
Advance Java Programming (CM5I) 2.Swing
Advance Java Programming (CM5I) 2.SwingAdvance Java Programming (CM5I) 2.Swing
Advance Java Programming (CM5I) 2.Swing
 
Programação GUI com jRuby
Programação GUI com jRubyProgramação GUI com jRuby
Programação GUI com jRuby
 

Semelhante a jquery examples

JQUERY EXAMPLE for Web Developer (Video Training Tutorial)
JQUERY EXAMPLE for Web Developer (Video Training Tutorial)JQUERY EXAMPLE for Web Developer (Video Training Tutorial)
JQUERY EXAMPLE for Web Developer (Video Training Tutorial)Kaml Sah
 
VISUAL CHEAT SHEET
VISUAL CHEAT SHEETVISUAL CHEAT SHEET
VISUAL CHEAT SHEETDanilo Sousa
 
J query 1.7 cheat sheet
J query 1.7 cheat sheetJ query 1.7 cheat sheet
J query 1.7 cheat sheetmaamir farooq
 
J query 17-visual-cheat-sheet1
J query 17-visual-cheat-sheet1J query 17-visual-cheat-sheet1
J query 17-visual-cheat-sheet1sdcasas
 
jQuery BootCamp : Creating the Wrapped Element Set
jQuery BootCamp : Creating the Wrapped Element SetjQuery BootCamp : Creating the Wrapped Element Set
jQuery BootCamp : Creating the Wrapped Element SetWildan Maulana
 
event handling new.ppt
event handling new.pptevent handling new.ppt
event handling new.pptusama537223
 
Introduction to jQuery
Introduction to jQueryIntroduction to jQuery
Introduction to jQuerySeble Nigussie
 
TAppWeb Training Material
TAppWeb Training MaterialTAppWeb Training Material
TAppWeb Training MaterialArvie Bernal
 
Unit 1 - What is jQuery_Why jQuery_Syntax_Selectors.pdf
Unit 1 - What is jQuery_Why jQuery_Syntax_Selectors.pdfUnit 1 - What is jQuery_Why jQuery_Syntax_Selectors.pdf
Unit 1 - What is jQuery_Why jQuery_Syntax_Selectors.pdfRAVALCHIRAG1
 
jQuery basics for Beginners
jQuery basics for BeginnersjQuery basics for Beginners
jQuery basics for BeginnersPooja Saxena
 
Zepto.js, a jQuery-compatible mobile JavaScript framework in 2K
Zepto.js, a jQuery-compatible mobile JavaScript framework in 2KZepto.js, a jQuery-compatible mobile JavaScript framework in 2K
Zepto.js, a jQuery-compatible mobile JavaScript framework in 2KThomas Fuchs
 
Javascript And J Query
Javascript And J QueryJavascript And J Query
Javascript And J Queryitsarsalan
 
TAppWeb Training Material
TAppWeb Training MaterialTAppWeb Training Material
TAppWeb Training MaterialArvie Bernal
 

Semelhante a jquery examples (20)

JQUERY EXAMPLE for Web Developer (Video Training Tutorial)
JQUERY EXAMPLE for Web Developer (Video Training Tutorial)JQUERY EXAMPLE for Web Developer (Video Training Tutorial)
JQUERY EXAMPLE for Web Developer (Video Training Tutorial)
 
VISUAL CHEAT SHEET
VISUAL CHEAT SHEETVISUAL CHEAT SHEET
VISUAL CHEAT SHEET
 
J query 1.7 cheat sheet
J query 1.7 cheat sheetJ query 1.7 cheat sheet
J query 1.7 cheat sheet
 
J query 17-visual-cheat-sheet1
J query 17-visual-cheat-sheet1J query 17-visual-cheat-sheet1
J query 17-visual-cheat-sheet1
 
jQuery BootCamp : Creating the Wrapped Element Set
jQuery BootCamp : Creating the Wrapped Element SetjQuery BootCamp : Creating the Wrapped Element Set
jQuery BootCamp : Creating the Wrapped Element Set
 
J query 1.5-visual-cheat-sheet
J query 1.5-visual-cheat-sheetJ query 1.5-visual-cheat-sheet
J query 1.5-visual-cheat-sheet
 
event handling new.ppt
event handling new.pptevent handling new.ppt
event handling new.ppt
 
J Query
J QueryJ Query
J Query
 
JQuery
JQueryJQuery
JQuery
 
Introduction to jQuery
Introduction to jQueryIntroduction to jQuery
Introduction to jQuery
 
TAppWeb Training Material
TAppWeb Training MaterialTAppWeb Training Material
TAppWeb Training Material
 
Java script basics
Java script basicsJava script basics
Java script basics
 
Unit 1 - What is jQuery_Why jQuery_Syntax_Selectors.pdf
Unit 1 - What is jQuery_Why jQuery_Syntax_Selectors.pdfUnit 1 - What is jQuery_Why jQuery_Syntax_Selectors.pdf
Unit 1 - What is jQuery_Why jQuery_Syntax_Selectors.pdf
 
jQuery basics for Beginners
jQuery basics for BeginnersjQuery basics for Beginners
jQuery basics for Beginners
 
Zepto.js, a jQuery-compatible mobile JavaScript framework in 2K
Zepto.js, a jQuery-compatible mobile JavaScript framework in 2KZepto.js, a jQuery-compatible mobile JavaScript framework in 2K
Zepto.js, a jQuery-compatible mobile JavaScript framework in 2K
 
Swing
SwingSwing
Swing
 
Java awt
Java awtJava awt
Java awt
 
Javascript And J Query
Javascript And J QueryJavascript And J Query
Javascript And J Query
 
TAppWeb Training Material
TAppWeb Training MaterialTAppWeb Training Material
TAppWeb Training Material
 
jQuery
jQueryjQuery
jQuery
 

Mais de Danilo Sousa

Iniciando com jquery
Iniciando com jqueryIniciando com jquery
Iniciando com jqueryDanilo Sousa
 
Iniciando com Jquery
Iniciando com JqueryIniciando com Jquery
Iniciando com JqueryDanilo Sousa
 
JQUERY CONF 2011Gwt kenjiyamamoto-111220113950-phpapp01
JQUERY CONF 2011Gwt kenjiyamamoto-111220113950-phpapp01JQUERY CONF 2011Gwt kenjiyamamoto-111220113950-phpapp01
JQUERY CONF 2011Gwt kenjiyamamoto-111220113950-phpapp01Danilo Sousa
 
Campus Party 2011 html 5
Campus Party 2011 html 5Campus Party 2011 html 5
Campus Party 2011 html 5Danilo Sousa
 
Ninja html 5 css javascript
Ninja html 5 css javascriptNinja html 5 css javascript
Ninja html 5 css javascriptDanilo Sousa
 
Alta produtividade com front end com sass e compass
Alta produtividade com front end com sass e compassAlta produtividade com front end com sass e compass
Alta produtividade com front end com sass e compassDanilo Sousa
 
Ux para agencias de publicidade
Ux para agencias de publicidade Ux para agencias de publicidade
Ux para agencias de publicidade Danilo Sousa
 

Mais de Danilo Sousa (10)

Sass - Tutorial
Sass - TutorialSass - Tutorial
Sass - Tutorial
 
Templates js-
Templates js-Templates js-
Templates js-
 
Iniciando com jquery
Iniciando com jqueryIniciando com jquery
Iniciando com jquery
 
Iniciando com Jquery
Iniciando com JqueryIniciando com Jquery
Iniciando com Jquery
 
JQUERY CONF 2011Gwt kenjiyamamoto-111220113950-phpapp01
JQUERY CONF 2011Gwt kenjiyamamoto-111220113950-phpapp01JQUERY CONF 2011Gwt kenjiyamamoto-111220113950-phpapp01
JQUERY CONF 2011Gwt kenjiyamamoto-111220113950-phpapp01
 
Campus Party 2011 html 5
Campus Party 2011 html 5Campus Party 2011 html 5
Campus Party 2011 html 5
 
Ninja html 5 css javascript
Ninja html 5 css javascriptNinja html 5 css javascript
Ninja html 5 css javascript
 
Alta produtividade com front end com sass e compass
Alta produtividade com front end com sass e compassAlta produtividade com front end com sass e compass
Alta produtividade com front end com sass e compass
 
CSS 3 Overview
CSS 3 OverviewCSS 3 Overview
CSS 3 Overview
 
Ux para agencias de publicidade
Ux para agencias de publicidade Ux para agencias de publicidade
Ux para agencias de publicidade
 

Último

Call girls Service in Ajman 0505086370 Ajman call girls
Call girls Service in Ajman 0505086370 Ajman call girlsCall girls Service in Ajman 0505086370 Ajman call girls
Call girls Service in Ajman 0505086370 Ajman call girlsMonica Sydney
 
Story Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr
Story Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrStory Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr
Story Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrHenryBriggs2
 
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制pxcywzqs
 
Ballia Escorts Service Girl ^ 9332606886, WhatsApp Anytime Ballia
Ballia Escorts Service Girl ^ 9332606886, WhatsApp Anytime BalliaBallia Escorts Service Girl ^ 9332606886, WhatsApp Anytime Ballia
Ballia Escorts Service Girl ^ 9332606886, WhatsApp Anytime Balliameghakumariji156
 
Meaning of On page SEO & its process in detail.
Meaning of On page SEO & its process in detail.Meaning of On page SEO & its process in detail.
Meaning of On page SEO & its process in detail.krishnachandrapal52
 
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查ydyuyu
 
一比一原版(Curtin毕业证书)科廷大学毕业证原件一模一样
一比一原版(Curtin毕业证书)科廷大学毕业证原件一模一样一比一原版(Curtin毕业证书)科廷大学毕业证原件一模一样
一比一原版(Curtin毕业证书)科廷大学毕业证原件一模一样ayvbos
 
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样ayvbos
 
Nagercoil Escorts Service Girl ^ 9332606886, WhatsApp Anytime Nagercoil
Nagercoil Escorts Service Girl ^ 9332606886, WhatsApp Anytime NagercoilNagercoil Escorts Service Girl ^ 9332606886, WhatsApp Anytime Nagercoil
Nagercoil Escorts Service Girl ^ 9332606886, WhatsApp Anytime Nagercoilmeghakumariji156
 
APNIC Policy Roundup, presented by Sunny Chendi at the 5th ICANN APAC-TWNIC E...
APNIC Policy Roundup, presented by Sunny Chendi at the 5th ICANN APAC-TWNIC E...APNIC Policy Roundup, presented by Sunny Chendi at the 5th ICANN APAC-TWNIC E...
APNIC Policy Roundup, presented by Sunny Chendi at the 5th ICANN APAC-TWNIC E...APNIC
 
20240507 QFM013 Machine Intelligence Reading List April 2024.pdf
20240507 QFM013 Machine Intelligence Reading List April 2024.pdf20240507 QFM013 Machine Intelligence Reading List April 2024.pdf
20240507 QFM013 Machine Intelligence Reading List April 2024.pdfMatthew Sinclair
 
pdfcoffee.com_business-ethics-q3m7-pdf-free.pdf
pdfcoffee.com_business-ethics-q3m7-pdf-free.pdfpdfcoffee.com_business-ethics-q3m7-pdf-free.pdf
pdfcoffee.com_business-ethics-q3m7-pdf-free.pdfJOHNBEBONYAP1
 
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查ydyuyu
 
APNIC Updates presented by Paul Wilson at ARIN 53
APNIC Updates presented by Paul Wilson at ARIN 53APNIC Updates presented by Paul Wilson at ARIN 53
APNIC Updates presented by Paul Wilson at ARIN 53APNIC
 
Real Men Wear Diapers T Shirts sweatshirt
Real Men Wear Diapers T Shirts sweatshirtReal Men Wear Diapers T Shirts sweatshirt
Real Men Wear Diapers T Shirts sweatshirtrahman018755
 
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girls
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girlsRussian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girls
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girlsMonica Sydney
 
best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...
best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...
best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...kajalverma014
 
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...gajnagarg
 
20240509 QFM015 Engineering Leadership Reading List April 2024.pdf
20240509 QFM015 Engineering Leadership Reading List April 2024.pdf20240509 QFM015 Engineering Leadership Reading List April 2024.pdf
20240509 QFM015 Engineering Leadership Reading List April 2024.pdfMatthew Sinclair
 

Último (20)

Call girls Service in Ajman 0505086370 Ajman call girls
Call girls Service in Ajman 0505086370 Ajman call girlsCall girls Service in Ajman 0505086370 Ajman call girls
Call girls Service in Ajman 0505086370 Ajman call girls
 
Story Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr
Story Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrStory Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr
Story Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr
 
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制
 
Ballia Escorts Service Girl ^ 9332606886, WhatsApp Anytime Ballia
Ballia Escorts Service Girl ^ 9332606886, WhatsApp Anytime BalliaBallia Escorts Service Girl ^ 9332606886, WhatsApp Anytime Ballia
Ballia Escorts Service Girl ^ 9332606886, WhatsApp Anytime Ballia
 
Meaning of On page SEO & its process in detail.
Meaning of On page SEO & its process in detail.Meaning of On page SEO & its process in detail.
Meaning of On page SEO & its process in detail.
 
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查
 
一比一原版(Curtin毕业证书)科廷大学毕业证原件一模一样
一比一原版(Curtin毕业证书)科廷大学毕业证原件一模一样一比一原版(Curtin毕业证书)科廷大学毕业证原件一模一样
一比一原版(Curtin毕业证书)科廷大学毕业证原件一模一样
 
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样
 
Nagercoil Escorts Service Girl ^ 9332606886, WhatsApp Anytime Nagercoil
Nagercoil Escorts Service Girl ^ 9332606886, WhatsApp Anytime NagercoilNagercoil Escorts Service Girl ^ 9332606886, WhatsApp Anytime Nagercoil
Nagercoil Escorts Service Girl ^ 9332606886, WhatsApp Anytime Nagercoil
 
APNIC Policy Roundup, presented by Sunny Chendi at the 5th ICANN APAC-TWNIC E...
APNIC Policy Roundup, presented by Sunny Chendi at the 5th ICANN APAC-TWNIC E...APNIC Policy Roundup, presented by Sunny Chendi at the 5th ICANN APAC-TWNIC E...
APNIC Policy Roundup, presented by Sunny Chendi at the 5th ICANN APAC-TWNIC E...
 
call girls in Anand Vihar (delhi) call me [🔝9953056974🔝] escort service 24X7
call girls in Anand Vihar (delhi) call me [🔝9953056974🔝] escort service 24X7call girls in Anand Vihar (delhi) call me [🔝9953056974🔝] escort service 24X7
call girls in Anand Vihar (delhi) call me [🔝9953056974🔝] escort service 24X7
 
20240507 QFM013 Machine Intelligence Reading List April 2024.pdf
20240507 QFM013 Machine Intelligence Reading List April 2024.pdf20240507 QFM013 Machine Intelligence Reading List April 2024.pdf
20240507 QFM013 Machine Intelligence Reading List April 2024.pdf
 
pdfcoffee.com_business-ethics-q3m7-pdf-free.pdf
pdfcoffee.com_business-ethics-q3m7-pdf-free.pdfpdfcoffee.com_business-ethics-q3m7-pdf-free.pdf
pdfcoffee.com_business-ethics-q3m7-pdf-free.pdf
 
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查
 
APNIC Updates presented by Paul Wilson at ARIN 53
APNIC Updates presented by Paul Wilson at ARIN 53APNIC Updates presented by Paul Wilson at ARIN 53
APNIC Updates presented by Paul Wilson at ARIN 53
 
Real Men Wear Diapers T Shirts sweatshirt
Real Men Wear Diapers T Shirts sweatshirtReal Men Wear Diapers T Shirts sweatshirt
Real Men Wear Diapers T Shirts sweatshirt
 
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girls
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girlsRussian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girls
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girls
 
best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...
best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...
best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...
 
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...
 
20240509 QFM015 Engineering Leadership Reading List April 2024.pdf
20240509 QFM015 Engineering Leadership Reading List April 2024.pdf20240509 QFM015 Engineering Leadership Reading List April 2024.pdf
20240509 QFM015 Engineering Leadership Reading List April 2024.pdf
 

jquery examples

  • 2. SELECTORS / 1. BASIC All Selector(“*”) Selects all elements. Class Selector (“.class”) Matches all elements with the given name. Element Selector (“element”) Selects all elements with the given tag name ID Selector (“#id”) Selects a single element with the given id attribute. Multiple Selector (“selector1, selector2, selectorN”) Selects the combined results of all the specified selectors.
  • 4. SELECTORS / 2. HIERARCHY Child Selector (“parent > child”) Selects all direct child elements specified by "child" of elements specified by "parent". Descendant Selector (“ancestor descendant”) Selects all elements that are descendants of a given ancestor. Next Adjacent Selector (“prev + next”) Selects all next elements matching "next" that are immediately preceded by a sibling "prev". Next Siblings Selector (“prev ~ siblings”) Selects all sibling elements that follow after the "prev" element, have the same parent, and match the filtering "siblings" selector.
  • 6. SELECTORS / 3. BASIC FILTER :eq() Selector Select the element at index n within the matched set. :even Selector Selects even elements, zero-indexed :first Selector Selects the first matched element. :gt() Selector Select all elements at an index greater than index within the matched set. :header Selector Selects all elements that are headers, like h1, h2, h3 and so on. :last Selector Selects the last matched element. :lt() Selector Select all elements at an index less than index within the matched set. :not() Selector Selects all elements that do not match the given selector. :odd Selector Selects odd elements, zero-indexed. See also even.
  • 8. SELECTORS / 4. CONTENT FILTER :contains() Selector Select all elements that contain the specified text. :has() Selector Selects elements which contain at least one element that matches the specified selector. :parent Selector Select all elements that are the parent of another element, including text nodes.
  • 10. SELECTORS / 5. ATTRIBUTE [attribute|=value] 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 (-). [attribute*=value] Selects elements that have the specified attribute with a value containing the a given substring. [attribute~=value] Selects elements that have the specified attribute with a value containing a given word, delimited by spaces. [attribute$=value] Selects elements that have the specified attribute with a value ending exactly with a given string. [attribute=value] Selects all elements that are matched specified value [attribute!=value] Select elements that either don't have the specified attribute, or do have the specified attribute but not with a certain value. [attribute^=value] Selects elements that have the specified attribute with a value beginning exactly with a given string. [attribute] Selects elements that have the specified attribute, with any value. [attribute=value] [attribute2=value2] Matches elements that match all of the specified attribute filters.
  • 12. SELECTORS / 6. CHILD FILTER :first-child Selector Selects all elements that are the first child of their parent. :last-child Selector Selects all elements that are the last child of their parent. :nth-child Selector Selects all elements that are the nth-child of their parent. :only-child Selector Selects all elements that are the only child of their parent.
  • 14. SELECTORS / 7. FORM (contd.) :button Selector Selects all button elements and elements of type button. :checkbox Selector Selects all elements of type checkbox. :checked Selector Matches all elements that are checked. :disabled Selector Selects all elements that are disabled. :enabled Selector Selects all elements that are enabled. :file Selector Selects all elements of type file. :image Selector Selects all elements of type image.
  • 15. SELECTORS / 7. FORM :input Selector Selects all input, textarea, select and button elements. :password Selector Selects all elements of type password. :radio Selector Selects all elements of type radio. :reset Selector Selects all elements of type reset. selected Selector Selects all elements that are selected. :submit Selector Selects all elements of type submit. :text Selector Selects all elements of type text.
  • 17. EVENTS / MOUSE EVENTS (contd.) .click( handler(eventObject) ) Bind an event handler to the "click" JavaScript event, or trigger that event on an element. .dblclick( handler(eventObject) ) Bind an event handler to the "dblclick" JavaScript event, or trigger that event on an element. .focusout( handler(eventObject) ) Bind an event handler to the "focusout" JavaScript event. .hover( handler(eventObject) ) Bind a single handler to the matched elements, to be executed when the mouse pointer enters or leaves the elements. .mousedown( handler(eventObject) ) Bind an event handler to the "mousedown" JavaScript event, or trigger that event on an element. .mouseenter( handler(eventObject) ) Bind an event handler to be fired when the mouse enters an element, or trigger that handler on an element.
  • 18. EVENTS / MOUSE EVENTS . mouseleave( handler(eventObje ct) ) Bind an event handler to be fired when the mouse leaves an element, or trigger that handler on an element. . mousemove( handler(eventObje ct) ) Bind an event handler to the "mousemove" JavaScript event, or trigger that event on an element. .mouseout( handler(eventObject) ) Bind an event handler to the "mouseout" JavaScript event, or trigger that event on an element. . mouseover( handler(eventObject ) ) Bind an event handler to the "mouseover" JavaScript event, or trigger that event on an element. . mouseup( handler(eventObject) ) Bind an event handler to the "mouseup" JavaScript event, or trigger that event on an element.
  • 20. EVENTS - FORM EVENTS .blur( handler(eventObject) ) Bind an event handler to the "blur" JavaScript event, or trigger that event on an element. .focus( handler(eventObject) ) Bind an event handler to the "focus" JavaScript event, or trigger that event on an element. .change( handler(eventObject) ) Bind an event handler to the "change“ JavaScript event, or trigger that event on an element. .select( handler(eventObject) ) Bind an event handler to the "select" JavaScript event, or trigger that event on an element. .submit( handler(eventObject) ) Bind an event handler to the "submit" JavaScript event, or trigger that event on an element.
  • 22. EVENTS - EVENT OBJECT .pageX The mouse position relative to the left edge of the document .pageY The mouse position relative to the top edge of the document. .type Describes the nature of the event. .target The DOM element that initiated the event. .preventDefault() If this method is called, the default action of the event will not be triggered. .isDefaultPrevented() Returns whether event.preventDefault() was ever called on this event object. .which For key or button events, this attribute indicates the specific button or key that was pressed
  • 24. ATTRIBUTES - CLASS .addClass( class ) Adds the specified class(es) to each of the set of matched elements. .removeClass( class ) Remove a single class, multiple classes, or all classes from each element in the set of matched elements. .hasClass( class ) Determine whether any of the matched elements are assigned the given class. .toggleClass( class, switch ) 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.
  • 26. CSS - POSITIONING .scrollLeft() Get the current horizontal position of the scroll bar for the first element in the set of matched elements. .scrollLeft( value ) Set the current horizontal position of the scroll bar for each of the set of matched elements. .offset() Get the current coordinates of the first element in the set of matched elements, relative to the document. .offset( coordinates ) Set the current coordinates of every element in the set of matched elements, relative to the document. .position() Get the current coordinates of the first element in the set of matched elements, relative to the offset parent. .scrollTop() Get the current vertical position of the scroll bar for the first element in the set of matched elements. .scrollTop( value ) Set the current vertical position of the scroll bar for each of the set of matched elements.
  • 28. TRAVERSING -TREE TRAVERSAL (cont.) .children( [ selector ] ) Get the children of each element in the set of matched elements, optionally filtered by a selector .closest( selector ) Get the first ancestor element that matches the selector, beginning at the current element and progressing up through the DOM tree. .find( selector ) Get the descendants of each element in the current set of matched elements, filtered by a selector. .next( [ selector ] ) Get the immediately following sibling of each element in the set of matched elements, optionally filtered by a selector. .nextAll( [ selector ] ) Get all following siblings of each element in the set of matched elements, optionally filtered by a selector.
  • 29. TRAVERSING -TREE TRAVERSAL (cont.) .nextUntil( [ selector ] ) Get all following siblings of each element up to but not including the element matched by the selector. .parent( [ selector ] ) Get the parent of each element in the current set of matched elements, optionally filtered by a selector. .parents( [ selector ] ) Get the ancestors of each element in the current set of matched elements, optionally filtered by a selector. .prev( [ selector ] ) Get the immediately preceding sibling of each element in the set of matched elements, optionally filtered by a selector.
  • 30. TRAVERSING -TREE TRAVERSAL .prevAll( [ selector ] ) Get all preceding siblings of each element in the set of matched elements, optionally filtered by a selector. .prevUntil( [ selector ] ) Get the ancestors of each element in the current set of matched elements, optionally filtered by a selector. .siblings( [ selector ] ) Get the siblings of each element in the set of matched elements, optionally filtered by a selector.
  • 32. TRAVERSING - FILTERING .eq( index ) Reduce the set of matched elements to the one at the specified index. .filter( selector ) Reduce the set of matched elements to those that match the selector or pass the function's test. .is( selector ) Check the current matched set of elements against a selector and return true if at least one of these elements matches the selector .not() Remove elements from the set of matched elements. .slice( start, [ end ] ) Reduce the set of matched elements to a subset specified by a range of indices. .map( callback(index, domEl) ) Pass each element in the current matched set through a function, producing a new jQuery object containing the return values.
  • 34. TRAVERSING - MISCELLANEOUS .add( selectors, [ context ] ) Add elements to the set of matched elements .andSelf() Add the previous set of elements on the stack to the current set. .contents() Get the children of each element in the set of matched elements, including text nodes. .end() End the most recent filtering operation in the current chain and return the set of matched elements to its previous state.
  • 36. ATTRIBUTES - ATTR .attr( attributeName ) Get the value of an attribute for the first element in the set of matched elements. .attr( attributeName, value ) Set one or more attributes for the set of matched elements. .removeAttr() Remove an attribute from each element in the set of matched elements.
  • 38. ATTRIBUTES - HTML .html() Get the HTML contents of the first element in the set of matched elements. .html( htmlString ) Set the HTML contents of each element in the set of matched elements.
  • 40. ATTRIBUTES - TEXT .text() Get the combined text contents of each Element in the set of matched elements, including their descendants. .text( textString ) Set the content of each element in the set of matched elements to the specified text.
  • 42. ATTRIBUTES - VALUE .val() Get the current value of the first element in the set of matched elements. .val( value ) Set the value of each element in the set of matched elements.
  • 44. CSS - CSS css( propertyName ) Get the value of a style property for the first element in the set of matched elements. .css( propertyName, value) Set one or more CSS properties for the set of matched elements.
  • 46. CSS - HEIGHT & WIDTH (cont.) .height( value ) Set the CSS height of every matched element. element in the set of matched elements. .height() Get the current computed height for the first .innerHeight() Get the current computed height for the first. element in the set of matched elements, including padding but not border .innerWidth() Get the current computed width for the first element in the set of matched elements, including padding but not border. .outerHeight() Get the current computed height for the first element in the set of matched elements, including padding, border, and optionally margin. .outerWidth() Get the current computed width for the first element in the set of matched elements, including padding and border.
  • 47. CSS - HEIGHT & WIDTH .width( value ) Set the CSS width of each element in the set of matched elements. .width() Get the current computed width for the first element in the set of matched element
  • 49. MANIPULATION - INSIDE .append( content ) Insert content, specified by the parameter, to the end of each element in the set of matched elements. .appendTo( target ) Insert every element in the set of matched elements to the end of the target. .prepend( content ) Insert content, specified by the parameter, to the beginning of each element in the set of matched elements. .prependTo( target ) Insert content, specified by the parameter, to the end of each element in the set of matched elements.
  • 51. MANIPULATION - OUTSIDE .after( content ) Insert content, specified by the parameter, after each element in the set of matched elements. .before( content ) Insert content, specified by the parameter, before each element in the set of matched elements. .insertAfter( target ) Insert every element in the set of matched elements after the target. .insertBefore( target ) Insert every element in the set of matched elements before the target.
  • 53. MANIPULATION - AROUND .wrap( wrappingElement ) Wrap an HTML structure around each element in the set of matched elements. .wrapAll( wrappingElement ) Wrap an HTML structure around all elements in the set of matched elements. .wrapInner( wrappingElement ) Wrap an HTML structure around the content of each element in the set of matched elements.
  • 55. MANIPULATION - REPLACING .replaceWith( newContent ) Replace each element in the set of matched elements with the provided new content. .replaceAll() A selector expression indicating which element(s) to replace.
  • 57. EVENTS - HANDLER ATTACHMENT .bind( eventType, [ eventData ], handler (eventObject) ) Attach a handler to an event for the elements. .unbind( eventType, handler (eventObject) ) Remove a previously-attached event handler from the elements. .die() Remove all event handlers previously attached using .live() from the elements. .live( eventType, eventData, handler ) Attach a handler to the event for all elements which match the current selector, now or in the future. .one( eventType, [ eventData ], handler (eventObject) ) Attach a handler to an event for the elements. The handler is executed at most once per element.
  • 59. EFFECTS - BASIC .hide( duration, [ callback ] ) Hide the matched elements. .show( duration, [ callback ] ) Display the matched elements.
  • 61. EFFECTS - SLIDING .slideDown( [ duration ], [ callback ] ) Display the matched elements with a sliding motion. .slideToggle( [ duration ], [ callback ] ) Display or hide the matched elements with a sliding motion. .slideUp( [ duration ], [ callback ] ) Hide the matched elements with a sliding motion.
  • 63. EFFECTS - FADING .fadeIn( [ duration ], [ callback ] ) Display the matched elements by fading them to opaque. .fadeOut( [ duration ], [ callback ] ) Hide the matched elements by fading them to transparent. .fadeTo( duration, opacity, [ callback ] ) Adjust the opacity of the matched elements.