/* prevent execution of jQuery if included more than once */
if(typeof window.jQuery == "undefined") {
/*
* jQuery 1.1.1 - New Wave Javascript
*
* Copyright (c) 2007 John Resig (jquery.com)
* Dual licensed under the MIT (MIT-LICENSE.txt)
* and GPL (GPL-LICENSE.txt) licenses.
*
* $Date: 2007-01-22 00:27:54 -0500 (Mon, 22 Jan 2007) $
* $Rev: 1153 $
*/
// Global undefined variable
window.undefined = window.undefined;
/**
* Create a new jQuery Object
*
* @constructor
* @private
* @name jQuery
* @param String|Function|Element|Array<Element>|jQuery a selector
* @param jQuery|Element|Array<Element> c context
* @cat Core
*/
var jQuery = function(a,c) {
// If the context is global, return a new object
if ( window == this )
return new jQuery(a,c);
// Make sure that a selection was provided
a = a || document;
// HANDLE: $(function)
// Shortcut for document ready
if ( jQuery.isFunction(a) )
return new jQuery(document)[ jQuery.fn.ready ? "ready" : "load" ]( a );
// Handle HTML strings
if ( typeof a == "string" ) {
// HANDLE: $(html) -> $(array)
var m = /^[^<]*(<(.|\n)+>)[^>]*$/.exec(a);
if ( m )
a = jQuery.clean( [ m[1] ] );
// HANDLE: $(expr)
else
return new jQuery( c ).find( a );
}
return this.setArray(
// HANDLE: $(array)
a.constructor == Array && a ||
// HANDLE: $(arraylike)
// Watch for when an array-like object is passed as the selector
(a.jquery || a.length && a != window && !a.nodeType && a[0] != undefined && a[0].nodeType) && jQuery.makeArray( a ) ||
// HANDLE: $(*)
[ a ] );
};
// Map over the $ in case of overwrite
if ( typeof $ != "undefined" )
jQuery._$ = $;
// Map the jQuery namespace to the '$' one
var $ = jQuery;
/**
* This function accepts a string containing a CSS or
* basic XPath selector which is then used to match a set of elements.
*
* The core functionality of jQuery centers around this function.
* Everything in jQuery is based upon this, or uses this in some way.
* The most basic use of this function is to pass in an expression
* (usually consisting of CSS or XPath), which then finds all matching
* elements.
*
* By default, $() looks for DOM elements within the context of the
* current HTML document.
*
* @example $("div > p")
* @desc Finds all p elements that are children of a div element.
* @before <p>one</p> <div><p>two</p></div> <p>three</p>
* @result [ <p>two</p> ]
*
* @example $("input:radio", document.forms[0])
* @desc Searches for all inputs of type radio within the first form in the document
*
* @example $("div", xml.responseXML)
* @desc This finds all div elements within the specified XML document.
*
* @name $
* @param String expr An expression to search with
* @param Element|jQuery context (optional) A DOM Element, Document or jQuery to use as context
* @cat Core
* @type jQuery
* @see $(Element)
* @see $(Element<Array>)
*/
/**
* Create DOM elements on-the-fly from the provided String of raw HTML.
*
* @example $("<div><p>Hello</p></div>").appendTo("#body")
* @desc Creates a div element (and all of its contents) dynamically,
* and appends it to the element with the ID of body. Internally, an
* element is created and it's innerHTML property set to the given markup.
* It is therefore both quite flexible and limited.
*
* @name $
* @param String html A string of HTML to create on the fly.
* @cat Core
* @type jQuery
* @see appendTo(String)
*/
/**
* Wrap jQuery functionality around a single or multiple DOM Element(s).
*
* This function also accepts XML Documents and Window objects
* as valid arguments (even though they are not DOM Elements).
*
* @example $(document.body).background( "black" );
* @desc Sets the background color of the page to black.
*
* @example $( myForm.elements ).hide()
* @desc Hides all the input elements within a form
*
* @name $
* @param Element|Array<Element> elems DOM element(s) to be encapsulated by a jQuery object.
* @cat Core
* @type jQuery
*/
/**
* A shorthand for $(document).ready(), allowing you to bind a function
* to be executed when the DOM document has finished loading. This function
* behaves just like $(document).ready(), in that it should be used to wrap
* all of the other $() operations on your page. While this function is,
* technically, chainable - there really isn't much use for chaining against it.
* You can have as many $(document).ready events on your page as you like.
*
* See ready(Function) for details about the ready event.
*
* @example $(function(){
* // Document is ready
* });
* @desc Executes the function when the DOM is ready to be used.
*
* @example jQuery(function($) {
* // Your code using failsafe $ alias here...
* });
* @desc Uses both the shortcut for $(document).ready() and the argument
* to write failsafe jQuery code using the $ alias, without relying on the
* global alias.
*
* @name $
* @param Function fn The function to execute when the DOM is ready.
* @cat Core
* @type jQuery
* @see ready(Function)
*/
jQuery.fn = jQuery.prototype = {
/**
* The current version of jQuery.
*
* @private
* @property
* @name jquery
* @type String
* @cat Core
*/
jquery: "1.1.1",
/**
* The number of elements currently matched.
*
* @example $("img").length;
* @before <img src="test1.jpg"/> <img src="test2.jpg"/>
* @result 2
*
* @property
* @name length
* @type Number
* @cat Core
*/
/**
* The number of elements currently matched.
*
* @example $("img").size();
* @before <img src="test1.jpg"/> <img src="test2.jpg"/>
* @result 2
*
* @name size
* @type Number
* @cat Core
*/
size: function() {
return this.length;
},
length: 0,
/**
* Access all matched elements. This serves as a backwards-compatible
* way of accessing all matched elements (other than the jQuery object
* itself, which is, in fact, an array of elements).
*
* @example $("img").get();
* @before <img src="test1.jpg"/> <img src="test2.jpg"/>
* @result [ <img src="test1.jpg"/> <img src="test2.jpg"/> ]
* @desc Selects all images in the document and returns the DOM Elements as an Array
*
* @name get
* @type Array<Element>
* @cat Core
*/
/**
* Access a single matched element. num is used to access the
* Nth element matched.
*
* @example $("img").get(0);
* @before <img src="test1.jpg"/> <img src="test2.jpg"/>
* @result [ <img src="test1.jpg"/> ]
* @desc Selects all images in the document and returns the first one
*
* @name get
* @type Element
* @param Number num Access the element in the Nth position.
* @cat Core
*/
get: function( num ) {
return num == undefined ?
// Return a 'clean' array
jQuery.makeArray( this ) :
// Return just the object
this[num];
},
/**
* Set the jQuery object to an array of elements, while maintaining
* the stack.
*
* @example $("img").pushStack([ document.body ]);
* @result $("img").pushStack() == [ document.body ]
*
* @private
* @name pushStack
* @type jQuery
* @param Elements elems An array of elements
* @cat Core
*/
pushStack: function( a ) {
var ret = jQuery(this);
ret.prevObject = this;
return ret.setArray( a );
},
/**
* Set the jQuery object to an array of elements. This operation is
* completely destructive - be sure to use .pushStack() if you wish to maintain
* the jQuery stack.
*
* @example $("img").setArray([ document.body ]);
* @result $("img").setArray() == [ document.body ]
*
* @private
* @name setArray
* @type jQuery
* @param Elements elems An array of elements
* @cat Core
*/
setArray: function( a ) {
this.length = 0;
[].push.apply( this, a );
return this;
},
/**
* Execute a function within the context of every matched element.
* This means that every time the passed-in function is executed
* (which is once for every element matched) the 'this' keyword
* points to the specific element.
*
* Additionally, the f
没有合适的资源?快使用搜索试试~ 我知道了~
JQuery文档以及文件包
共34个文件
js:13个
xsl:5个
png:5个
4星 · 超过85%的资源 需积分: 9 45 下载量 43 浏览量
2009-08-07
09:33:06
上传
评论
收藏 459KB RAR 举报
温馨提示
jQuery 是一个新型的JavaScript库; jQuery是一个简洁快速的JavaScript库,它能让你在你的网页上简单的操作文档、处理事件、运行动画效果或者添加Ajax交互。jQuery的设计会改变你写JavaScript代码的方式。 jQuery适合于设计师、开发者以及那些还好者,同样适合用于商业开发,可以说jQuery适合任何JavaScript应用的地方,可用于不用的应用程序。 jQuery是一个轻量级的脚本,其代码非常小巧,JavaScript包只有15K左右。 jQuery支持CSS1-CSS3,以及基本的xPath jQuery是跨浏览器的,它支持的浏览器包括IE 6.0+, FF 1.5+, Safari 2.0+, Opera 9.0+
资源推荐
资源详情
资源评论
收起资源包目录
JQuery+API.rar (34个子文件)
JQuery+API
jQuery1.1_API
jquery1.1_api_cn.xml 136KB
jquery1.1_api_en.xml 113KB
dist
jquery.src.js 145KB
wait.gif 1KB
jquery.pack.js 20KB
minmax.js 4KB
jquery.js 56KB
js
pager.js 3KB
doc.js 1KB
tooltip.js 2KB
doc_cn.js 2KB
style
docs_cn.xsl 3KB
style.css 2KB
docs.xsl 3KB
JQuery API.CHM 52KB
jquery_api.chm 118KB
Visual JQuery-API.CHM 88KB
visual_jquery
javascripts
center.js 1KB
iutil.js 6KB
visual_jquery.js 1KB
jq-corners.js 3KB
jquery.js 56KB
stylesheets
site.css 3KB
visualjquery1.1_en.xml 171KB
styles
cat.xsl 4KB
cat_cn.xsl 4KB
site.css 3KB
images
cat.xsl 4KB
red-button.png 899B
page-top.png 20KB
header.png 646B
grey-button-wide.png 836B
blue-button-wide.png 862B
vjq1.1_cn.xml 196KB
共 34 条
- 1
资源评论
- Zouman_law2013-10-07简单。有用,还不错、
- wwwal2012-09-28简单。有用,还不错、。
ccp330
- 粉丝: 1
- 资源: 52
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功