jQuery
Dosed by Baskar P, Vaidehi Kumari – M & E Team (from MphasiS Software Services)
What is jQuery?
jQuery is a popular JavaScript library. With jQuery, you can build more
interesting and interactive web page easy. jQuery automate common tasks and
simplify complicated writing code. jQuery have ability to assist in wide range
of task. This is one reason this library become popular choice.
What jQuery does?
• Access parts of page. jQuery offers a robust and efficient selector mechanism
for retrieving exactly the piece of the document that is to be inspected or
manipulated.
• Modify the appearance of a page. jQuery can bridge CSS browser standard gap.
• Alter the content a page. jQuery can modify texts, images, list, and entire
of the HTML. All with a single easy-to-use API.
• Respond to a user's interaction with a page. The jQuery library have an
elegant way to intercept a wide variety of events without the need to clutter
the html code itself with event handlers.
• Add animation. Implementing such interactive behaviors.
• AJAX support. Retrieve information from server without refreshing a page.
• Simplify common JavaScript task.
How jQuery works?
Download and extract a copy of jQuery library (jquery.js) and insert it in your
html page (preferably within the <head> tag). Then you need to write functions
to tell jQuery what to do. The diagram below explains the detail how jQuery
work:
Here’s an example to make you understand better:
<html>
<head>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript">
$(document).ready(function()
{
$("a").click(function()
{
alert("Hello world!");
});
});
</script>
</head>
<body>
<a href="">Link</a>
</body>
</html>
This should show the alert as soon as you click on the link.
What are the benefits?
• Few lines of code of jQuery can perform better task than more lines of
traditional JavaScript code.
• Various number of plug-ins are available and a large community support this
project it is better to use jQuery in your project compared to other JavaScript
frameworks like prototype.js or moottools .
• jQuery's website contains very good documentation with useful examples.
• It simplifies the Ajax Development. Just have to write 5 or 6 lines to call
the Ajax.
Well these are just few benefits of jQuery but if you start using jQuery then
you'll come to know about the actual benefits of using jQuery in your web
applications.
Further References
http://jquery.com/
http://en.wikipedia.org/wiki/JQuery
Did you know? You can CHAT without downloading messenger. Go to
http://in.webmessenger.yahoo.com/
Join Access India convention: For updates on it visit:
http://accessindia.org.in/harish/convention.htm
Registration is now open!
To unsubscribe send a message to [EMAIL PROTECTED] with the subject unsubscribe.
To change your subscription to digest mode or make any other changes, please
visit the list home page at
http://accessindia.org.in/mailman/listinfo/accessindia_accessindia.org.in