Monday, June 25, 2012

What is jQuery and how to start using jQuery?

jQuery is not a language but it is a well written JavaScript code, As quoted on official jQuery website “it is a fast and concise JavaScript Library that simplifies HTML document traversing, event handling, animating, and Ajax interactions for rapid web development“.

What is jQuery

jQuery is not a language but it is a well written JavaScript code, As quoted on official jQuery website “it is a fast and concise JavaScript Library that simplifies HTML document traversing, event handling, animating, and Ajax interactions for rapid web development.“
In order to work with jQuery you should be aware of basics of JavaScript, HTML and CSS.
It was released in January 2006 at BarCamp NYC by John Resig.
Licensing: It is free, open source software Dual-licensed under the MIT License and the GNU General Public License. Microsoft has integrated jQuery officially into its IDE Visual Studio 2010 and jQuery intellisense is available in Visual Studio 2010 now.
This is the first chapter of my jQuery ebook.
Why jQuery
jQuery is very compact and well written JavaScript code that increases the productivity of the developer by enabling them to achieve critical UI functionality by writing very less amount of code.
It helps to
•  Improve the performance of the application
•  Develop most browser compatible web page
•  Implement UI related critical functionality without writing hundreds of lines of codes
•  Fast
•  Extensible – jQuery can be extended to implement customized behavior
Other advantages of jQuery are
•  No need to learn fresh new syntaxes to use jQuery, knowing simple JavaScript syntax is enough
•  Simple and Cleaner code, no need to write several lines of codes to achieve complex functionality.

Where to download jQuery from

jQuery javascript file can be downloaded from jQuery Official website http://www.jquery.com/

How to use jQuery

jQuery usually comes as a single JavaScript file containing everything comes out of the box with jQuery. It can be included within a web page using the following mark-up:

To load local jQuery file
<script type="text/javascript" src="jQuery-1.4.1-min.js">script>

Ideally this markup is kept in under tag of your web page, however you are free to keep anywhere you want.

Do I need to refer jQuery file both in Master page/base page/template page and content page

No, master page/base page/ template page basically helps to create consistent layout for the page in the application. In case you have referred the jQuery file in master page/base page/ template page that cause rendering the file in the browser, you do not need to refer jQuery file the content page again.
In summary, there should not be more than one

0 comments:

Post a Comment

I am a student of MS(CS), and also a computer software engineer and web developer.