The definition of jquery

Source: Internet
Author: User
Tags jquery library

jquery is another excellent JavaScript library following prototype. It is a lightweight JS library, it is compatible with CSS3, also compatible with various browsers (IE 6.0+, ff1.5+, Safari 2.0+, Opera 9.0+), jQuery2.0 and subsequent versions will no longer support Ie6/7/8 browser. jquery makes it easier for users to work with HTML (an application under the standard Universal Markup Language), events, animate, and easily provide Ajax interactivity to the site. One of the big advantages of jquery is that its documentation is full, and the various applications are very detailed, as well as a number of mature plugins to choose from. jquery allows the user's HTML page to keep the code and HTML content separate, that is, no more inserting a bunch of JS in the HTML to invoke the command, only need to define the ID. jquery is a multi-browser-compatible JavaScript library, with the core idea of write Less,do more (write less and do more). Published in January 2006 by American John Resig in New York's BarCamp, jquery attracted a number of JavaScript gurus from around the world and was developed by Dave Methvin's team. Today, jquery has become the most popular JavaScript library, with more than 55% of the world's top 10,000 most visited sites using jquery. jquery is free, open source, and uses the MIT license Agreement. jquery's syntax is designed to make development easier, such as manipulating document objects, selecting DOM elements, animating effects, event handling, using AJAX, and other features. In addition, JQuery provides APIs for developers to write plugins. Its modular approach makes it easy for developers to develop powerful static or dynamic Web pages. JQuery, as its name implies, is JavaScript and query, which is a library of auxiliary JavaScript development.
  1. Dynamic effects
  2. Ajax
  3. Extending through plugins
  4. Convenient tools-such as browser version judgment
  5. Progressive enhancement
  6. Chained calls
  7. Multi-browser support, support for Internet explorer6.0+, opera9.0+, firefox2+, safari2.0+, chrome1.0+ (removing support for Internet 2.0.0 in explorer6,7,8) makes Method: jquery can be downloaded using, there are two versions of jquery available for download production version-used in the actual website, has been streamlined and compressed. Development version-for testing and development (uncompressed, readable code) comparison before and after compression in JQuery version 1.8.0
    File Number of rows Size
    Jquery-1.8.0.min.js 2 91KB
    Jquery-1.8.0.js 9228 254KB
    These two versions are available for download from the jquery.com website. You can also select references from multiple public services. Storing jquery in a CDN Public library speeds up website loading, and CDN Common Library refers to placing the usual JS inventory on the CDN node to facilitate direct invocation by the vast number of developers. Compared with the JS inventory on the server machine, the CDN Public Library is more stable and high-speed. Google, Microsoft and other companies abroad to provide a CDN service to jquery, the domestic by Sina Cloud Computing (SAE), Baidu Cloud (BAE) and so on to introduce a few relatively more stable CDN. and have jquery1.1 to 2.0 all editions download share Google CDN
    1 <script type="text/javascript"src="http://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js"></script>
    Tip: Get the latest available version from Google CDN: If you look at the Google URL above-the jQuery version (1.8.0) is specified in the URL. If you want to use the latest version of JQuery, you can also delete a number from the end of the version string (example 1.8), Google will return to the latest available version of the 1.8 series (1.8.0, 1.8.1, etc.), or the first number can be left, then Google will return 1 The latest available version in the series (from 1.1.0 to 1.9.9). Microsoft Cdn[3]
    1 <script type="text/javascript"src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-2.1.0.min.js"></script>
    Tip: Using Google or Microsoft's jquery has a big advantage: Many users have already loaded jquery from Google or Microsoft when they visit other sites. All the results are that when they visit your site, JQuery is loaded from the cache, which reduces the load time. At the same time, most cdns ensure that when a user requests a file, the response is returned from the server closest to the user, which can also increase the load speed. Sina Cdn[4]
    1 <script type="text/javascript"src="http://libs.baidu.com/jquery/2.0.3/jquery.min.js"></script>
    Baidu CDN [5]
    1 <script type="text/javascript"src="http://libs.baidu.com/jquery/2.0.3/jquery.min.js"></script>
    To be safe, use local jquery when you cannot get jquery from a CDN server
    1 <script type="text/javascript">window.jQuery||document.write(‘<scriptsrc="//localhost/jQuery/jquery-2.1.0.min.js"><\/script>‘);</script>
    The methods used in WordPress themes are
    1 <script type="text/javascript">window.jQuery||document.write(‘<scripttype="text/javascript"src="<?phpechoget_template_directory_uri();?>/jquery.min.js">\x3C/script>‘)</script>
    Note 1, WordPress built-in jquery library, its end to prevent JS Library conflict and added jquery.noconflict () so that all the jquery code in the theme to do some minor changes, more likely to cause some plug-in effect invalidation. WordPress recommends downloading the official Jquery-min library to the current theme directory down, do not use the wp-includes inside the library. 2, the address of the Google CDN Library adopts the Protocol relative path, it can solve some problems caused by HTTPS, specifically can see Paul Irish's introduction, of course, you can still use the path with "http:". 3. Many websites use the jquery library provided by Google CDN, which can be used to achieve excellent caching effect. 4. Put jquery code at the bottom of the page to increase loading speed. 5, use HTML5 reconstruction page can omit type= "Text/javascript". 6, the recommended use of domestic CDN Public Library, faster, more stable.

The definition of jquery

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.