这两个方法用的是相同的代码,一个用于给jQuery对象或者普通对象合并属性和方法一个是针对jQuery对象的实例,对于基本用法举几个例子:html代码如下: 下面写js里面的用法:合并两个普通对象 //给两个普通对象合并属性 ...
分类:
Web程序 时间:
2015-06-02 15:10:35
阅读次数:
120
js插件代码如下:$.fn.extend({ //焦点图 INA_focus:function(opt,callback){ if(!opt){} var _this=$(this),nr=_this.find(opt.qhys||"img"),controls=opt.controls||"...
分类:
其他好文 时间:
2015-06-02 15:00:01
阅读次数:
91
The Fibonacci sequence is defined by the recurrence relation:
Fn = Fn?1 + Fn?2, where F1 = 1 and F2 = 1.
Hence the first 12 terms will be:
F1 = 1
F2 = 1
F3 = 2
F4 = 3
F5 = 5
F6 = 8
F7 = 1...
分类:
其他好文 时间:
2015-06-02 00:33:24
阅读次数:
168
一、jQuery插件开发分为两种:
1.类级别:
类级别你可以理解为拓展jquery类,最明显的例子是$.ajax(...),相当于静态方法。
开发扩展其方法时使用$.extend方法,即jQuery.extend(object);
$.extend({
add:function(a,b){return a+b;} ,
minus:function(a...
分类:
Web程序 时间:
2015-06-01 13:19:57
阅读次数:
143
var _timer = {};function delay_till_last(id, fn, wait) { if (_timer[id]) { window.clearTimeout(_timer[id]); delete _timer[id]; } ...
分类:
其他好文 时间:
2015-06-01 13:02:17
阅读次数:
93
Mac键盘图标与对应快捷按键?——Command (?)? ——Control?——Option (alt)?——Shift?——Caps Lockfn——功能键就是fn*.m*.h切换 ?+? +↓or↑前进后退文本文件?+? +←or→关闭当前文本文件?+?+w自动排版代码 ?+i左右缩进 ?+...
分类:
系统相关 时间:
2015-06-01 11:32:00
阅读次数:
223
Insert title here"${ pageContext.request.requestURL }" 的长度:${ fn:length(pageContext.request.requestURI) } Cookie[] 的长度:${ fn:length(pageContext.reques...
分类:
其他好文 时间:
2015-06-01 11:24:44
阅读次数:
133
Insert title herefn:indexOf('filename.txt', '.') = ${ fn:indexOf('filename.txt', '.') }
分类:
其他好文 时间:
2015-06-01 11:21:58
阅读次数:
126
Insert title here${ fn:join(array, '; ') }
分类:
其他好文 时间:
2015-06-01 11:21:55
阅读次数:
123
Insert title here${ fn:escapeXml(source) }
分类:
Web程序 时间:
2015-06-01 11:18:50
阅读次数:
198