jQuery 核心函数
jQuery([sel,[context]])
jQuery(html,[ownerDoc])1.8*
jQuery(callback)
jQuery.holdReady(hold)
jQuery 对象访问
each(callback)
size()
length
selector
context
get([index])
index([selector|element])
数据缓存
data([key],[value])
removeData([name|list])1.7*
$.data(ele,[key],[val])1.8-
队列控制
queue(e,[q])
dequeue([queueName])
clearQueue([queueName])
插件机制
jQuery.fn.extend(object)
jQuery.extend(object)
多库共存
jQuery.noConflict([ex])
属性
attr(name|pro|key,val|fn)
removeAttr(name)
prop(n|p|k,v|f)
removeProp(name)
CSS 类
addClass(class|fn)
removeClass([class|fn])
toggleClass(class|fn[,sw])
HTML代码/文本/值
html([val|fn])
text([val|fn])
val([val|fn|arr])
CSS
css(name|pro|[,val|fn])1.9*
jQuery.cssHooks
位置
offset([coordinates])
position()
scrollTop([val])
scrollLeft([val])
尺寸
height([val|fn])
width([val|fn])
innerHeight()
innerWidth()
outerHeight([soptions])
outerWidth([options])
基本
#id
element
.class
*
selector1,selector2,selectorN
层级
ancestor descendant
parent > child
prev + next
prev ~ siblings
基本
:first
:not(selector)
:even
:odd
:eq(index)
:gt(index)
:lang1.9+
:last
:lt(index)
:header
:animated
:focus
:root1.9+
:target1.9+
内容
:contains(text)
:empty
:has(selector)
:parent
可见性
:hidden
:visible
属性
[attribute]
[attribute=value]
[attribute!=value]
[attribute^=value]
[attribute$=value]
[attribute*=value]
[attribute~=value]
[attribute|=value]
[attrSel1][attrSel2][attrSelN]
子元素
:first-child
:first-of-type1.9+
:last-child
:last-of-type1.9+
:nth-child
:nth-last-child()1.9+
:nth-last-of-type()1.9+
:nth-of-type()1.9+
:only-child
:only-of-type1.9+
表单
:input
:text
:password
:radio
:checkbox
:submit
:image
:reset
:button
:file
表单对象属性
:enabled
:disabled
:checked
:selected
混淆选择器
$.escapeSelector(selector)3.0+
内部插入
append(content|fn)
appendTo(content)
prepend(content|fn)
prependTo(content)
外部插入
after(content|fn)
before(content|fn)
insertAfter(content)
insertBefore(content)
包裹
wrap(html|ele|fn)
unwrap()
wrapAll(html|ele)
wrapInner(html|ele|fn)
替换
replaceWith(content|fn)
replaceAll(selector)
删除
empty()
remove([expr])
detach([expr])
复制
clone([Even[,deepEven]])
过滤
eq(index|-index)
first()
last()
hasClass(class)
filter(expr|obj|ele|fn)
is(expr|obj|ele|fn)
map(callback)
has(expr|ele)
not(expr|ele|fn)
slice(start,[end])
查找
children([expr])
closest(e|o|e)1.7*
find(e|o|e)
next([expr])
nextall([expr])
nextUntil([e|e][,f])
offsetParent()
parent([expr])
parents([expr])
parentsUntil([e|e][,f])
prev([expr])
prevall([expr])
prevUntil([e|e][,f])
siblings([expr])
串联
add(e|e|h|o[,c])1.9*
andSelf()1.8-
addBack()1.9+
contents()
end()