jquery document loading several writing, picture loading notation

Source: Internet
Author: User

jquery Document loading notation:

$ (function// personal most commonly used by $ (document). Ready (function() {     // call the Ready method under the Document object to pass in a function.  $ (window). Load (function() {}); // call the Load method under the Window object to pass in a function. (function() {}) (jquery)//() () means immediate execution and incoming jquery = $ so the $ can be replaced with jquery before 

Attention:

The ready for jquery is just the structure of the DOM loaded, and it is considered to be loading complete. Regardless of whether the content is loaded or not

JS Window.onload refers to the creation of the DOM and the loading of resources, such as Flash, the picture is fully loaded before the onload execution. (The disadvantage is that when a picture is large, it will not prevent the normal execution of other JS)

JS notation:

function () {};d ocument.ready=function() {};

Picture loading complete:

No plagiarism: http://www.cnblogs.com/ymy124/p/4538695.html

jquery document loading several writing, picture loading notation

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.