标签:
Functions are the basic unit of action in jQuery.
a function is made up of three parts:
$(document).ready(function(){ });
$(document) is jQuery object. The$()
is actually a function in disguise; it turns the document
into a jQuery object.
.ready() is a type of function; you can think of it as sort of a helper that runs the code inside its parentheses as soon as the HTML document is ready.
function(){}
is the action that.ready()
will perform as soon as the HTML document is loaded.
标签:
原文地址:http://www.cnblogs.com/elewei/p/5721168.html