Loading jQuery in Your Web Pages

<head>   <script src="local/jquery-2.0.3.min.js"></script> . . . or . . .   <script src=     "http://code.jquery.com/jquery-2.0.3.min.js">   </script> </head>

The jQuery library is just a .js file. You can load it just like any other JavaScript file. There are two ways to add jQuery to your web page.

The easiest method of adding jQuery to web pages is to use one of the several Content Discovery Network locations, or CDNs. A CDN allows you to load the libraries from a network of jQuery hosting servers spread globally. The benefit of this method is that the servers are spread globally so the downloads are distributed to multiple servers. Also, if the user has loaded another web ...

Get jQuery and JavaScript Phrasebook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.