使用jquery的时候一种方式是从jQuery.com上下载jQuery的库;
jQuery 库是一个 JavaScript 文件,您可以使用 HTML 的 <script> 标签引用它:
<head> <script src="jquery.js"></script> </head>
另一种方式是从google或者Microsoft加载CDNjQuery核心文件。
请注意,<script> 标签应该位于页面的 <head> 部分。
<head>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs
/jquery/1.4.0/jquery.min.js"></script>
</head>
<head>
<script type="text/javascript" src="http://ajax.microsoft.com/ajax/jquery
/jquery-1.4.min.js"></script>
</head>