Category: Built-in Methods

  • Events Methods

    Category Method Description Form events blur Attaches or fires JavaScript “blur” event (when cursor go out from the input element). change Attach or fire JavaScript “change” event. focus Attach or fire JavaScript “focus” event. focusin Attach event handler for “focusin” event. select Attach or fire JavaScript “select” event. submit Attach or fire JavaScript “submit” event.…

  • Effect Methods

    Method Description animate() Perform custom animation using element’s style properties. Example: $(‘#myDiv’).animate({ height: ‘200px’, width: ‘200px’}); clearQueue() Remove all the animations from the queue that have not been run. Example: $(‘#myDiv’).clearQueue(); delay() Set a timer to delay execution of animations in the queue. Example: $(‘#myDiv’).delay(5000); dequeue() Execute the next animation in the queue for the selected element. Example: $(‘#myDiv’).dequeue();…

  • DOM Traversing Methods

    Method Description add() Creates a single jQuery object for all added elements, so that it will be easy to manipulate them at the same time. addBack() Creates a single jQuery object for the set of selected elements by selector. children() Get all the child elements of the selected element(s). closest() Traversing up through its ancestors…

  • DOM Manipulation Methods

    Method Description append Inserts DOM elements at the end of selected element(s). appendTo Perform same task as append() method. The only difference is syntax. Here, first specify DOM elements as a string which you want to insert and then call appendTo() method with selector expression to select the elements where you want to append the…

  • Selector Reference

    Selector Pattern Example Description Element $(‘div’) Selects all <div> elements :first $(‘div:first’) Selects first <div> element in a DOM hierarchy. :last $(‘div:last’) Selects last <div> element in a DOM hierarchy. Multiple elements $(‘p, div, code’) Selects <p>,<div> and <code> elements parent descendant $(‘div p’) Selects all <p> elements which is descendant of <div> parent child…