X

Login




show

Forgot Password?
X

Enter Your Email






X

Register






 
 
Lessons
लेसन के लिए इस बटन पर क्लिक करें

JQUERY : Intro



1. jQuery is a JavaScript Library.
2. The purpose of jQuery is to make it much easier to use JavaScript on your website.

What is jQuery?

1. jQuery is a lightweight, "write less, do more", JavaScript library.
2. jQuery takes a lot of common tasks that require many lines of JavaScript code to accomplish, and wraps them into methods that you can call with a single line of code.

jQuery Syntax

Basic syntax is:
$(selector).action()

Examples:


1. $(this).hide() - hides the current element.

2. $("p").hide() - hides all <p> elements.

3. $(".test").hide() - hides all elements with class="test".

4. $("#test").hide() - hides the element with id="test".


The Document Ready Event



You might have noticed that all jQuery methods in our examples, are inside a document ready event:

$(document).ready(function(){

// jQuery methods go here...

});

-

Next Lesson