This has already been mentioned, but I will say it again: jQuery. The power of jQuery is not just the ability to make a simple AJAX call or a large library of UI extensions. In my humble opinion, the best part of jQuery is how you can easily handle the returned data. jQuery easily allows you to navigate XML just like HTML.
For example, let's say you get an xml request:
(: Borrowed this XML from the MarkLogic training file :)
<author name="Boynton"> <book> <title>Barnyard Dance!</title> <year>1993</year> </book> <book> <title>Hippos Go Berserk!</title> <year>1996</year> </book> </author>
jQuery can retrieve all the elements of the year with this simple command:
var years = $("year"); //Ok, lets act on each element instead $("year").each(function(index, value){ alert("Element " + index + " = " + value); }); /* OUTPUT Element 0 = 1993 Element 1 = 1996 /*
Try to do it in plain Javascript!
In addition, the jQuery method is designed just beautifully. Founders encourage the extension of the structure by adding the ability to create extensions to the core of the library (of course, you can always simply edit the Javascript file, but what happens when a critical update for the framework).
Another big reason to use jQuery is its compatibility with other Javascript frameworks. By default, both Prototype and jQuery use the $ sign to refer to the main library object. Only jQuery adds functions to remove this link so that it can coexist with Prototype.
jQuery makes JavaScript nice.
source share