It can be referenced through CDN (Content Delivery Network). jQuery is stored on both Google and Microsoft's servers. Google CDN: Copy code The code is as follows:<head> <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.0/jquery.min.js"> </script> </head> Get the latest available version via Google CDN: If you observe the URL on Google - the jQuery version (1.8.0) is specified in the URL. If you want the latest version of jQuery, you can either remove a number from the end of the version string (such as 1.8 in this case) and Google will return the latest available version in the 1.8 series (1.8.0, 1.8.1, and so on) or leave the first number alone and Google will return the latest available version in the 1 series (from 1.1.0 to 1.9.9). Microsoft CDN: Copy code The code is as follows:<head> <script src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.8.0.js"> </script> </head> Using jQuery from Google or Microsoft has one big advantage: Many users have already loaded jQuery from Google or Microsoft when visiting other sites. All the result is that when they visit your site, jQuery will be loaded from cache, which should reduce loading times. At the same time, most CDNs can ensure that when a user requests a file, a response is returned from the server closest to the user, which can also increase loading speed. |
<<: CSS implements six adaptive two-column layout methods
>>: Detailed tutorial of using stimulsoft.reports.js with vue-cli
Table of contents 1. setState() Description 1.1 U...
Table of contents npm download step (1) Import (2...
1. Description In MySQL, when we need to get the ...
Three tables are connected. Field a of table A co...
Problem Description 1. Database of the collection...
This article shares the specific code of JS objec...
Table of contents Packaging, launching and optimi...
The requirements are as follows: There are multip...
Description: Limit the number of lines of text di...
Preface Only Innodb and MyISAM storage engines ca...
1. Property List Copy code The code is as follows:...
<frameset></frameset> is familiar to e...
General mobile phone style: @media all and (orien...
In daily operation and maintenance work, backup o...