`
enix2212
  • 浏览: 25229 次
  • 性别: Icon_minigender_1
  • 来自: 北京
最近访客 更多访客>>
社区版块
存档分类
最新评论
文章列表
原生态javascript,希望大家能喜欢 function Gametimeline(){var c=document,a=arguments.callee,b=this;b.parent=c.getElementById("GameModuleTimeline"),b.hand=c.getElementById("GametimelineHandler"),b.handler=b.hand.getElementsByTagName("b"),b.date=b.hand.getElementsByTagName("spa ...

fade方法

function fadeOut(steps){ doFade.call(this,steps/10,1,false); }; function fadeIn(steps){ doFade.call(this,steps/10,0,true); }; function doFade(steps,value,action,fn){ var ie=undefined!==window.ActiveXObject,calls=arguments.callee,t=this,step; value+=(action?1:- ...
<div id="abc" class="same new yes">1111111</div> 改进版 只有一行 function removeClass(value){ var kls,reg=1>0 &&(kls=this.className,reg=new RegExp('(^| )'+value+'( |$)'),reg.test(this.className) && (this.className=(kls.replace(reg,'$1')).replace ...
function addEvent(elem,evType,fn,userCapture){ var indicator=arguments.callee; if(elem.addEventListener){ indicator=function(){ elem.addEventListener(evType,fn,userCapture || false); }() }else if(elem.attachEvent){ indicator=function(){ elem.attachEvent('on'+evType,fn); }( ...
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; cha ...
function javascriptNew(t){ a=Object.call(null,t); a.__proto__=Object.prototype.toString.call(a).split(' ')[0].prototype; return a; } var d=javascriptNew('123 3'); console.log(typeof d); console.log(Object.prototype.toString.call(d)); alert(d.split(' ')[1]) javascript的new运算符的运算原理大抵如此。基 ...
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset ...
Global site tag (gtag.js) - Google Analytics