jQuery is a fast, small, and feature-rich client side JavaScript library.
Makes things like HTML document traversal and manipulation, event handling, animation, and Ajax much simpler with an easy-to-use API that works across a multitude of browsers.
Whenever html manipulation is needed. Issuing ajax requests registering for DOM events, etc.
When building sophisticated single page web applications.
For this kind of tasks a more elaborate client library will be needed like KnockoutJS, Backbone or AngularJS.
A lot of resources in the jQuery site
A good set of examples can be found at:
Example 1 -Hide an element with id "textbox“
//javascript
document.getElementById('textbox').style.display = "none";
//jQuery
$('#textbox').hide();
Example 2 - create a <h1> tag with "my text"
//javascript
var h1 = document.CreateElement("h1");
h1.innerHTML = "my text";
document.getElementsByTagName('body')[0].appendChild(h1);
//jQuery
$('body').append( $("<h1/>").html("my text") );
// dissapearing links
$( "a" ).click(function( event ) {
event.preventDefault();
$( this ).hide( "slow" );
});
$.get( "myhtmlpage.html", function() {
// issues an AJAX http get for the myhtmlpage.html file
});