Search completed in 1.37 seconds.
13 results for "attachEvent":
Forms related code snippets - Archive of obsolete content
ArchiveAdd-onsCode snippetsForms
addeventlistener("load", buildcalendars, false) : window.attachevent ?
... attachevent("onload", buildcalendars) : (onload = buildcalendars); document.addeventlistener ?
... document.addeventlistener("mousedown", ondocclick, false) : document.attachevent ?
... document.attachevent("onmousedown", ondocclick) : (document.onmousedown = ondocclick); })(); </script> <style type="text/css"> table.zdp-calendar { border: 1px solid #666666; border-collapse: collapse; background-color: #cccccc; cursor: default; font-family: verdana; font-size: 12px; } table.zdp-calendar th { border: 1px solid #666666; font-weight: bold; background-color: #ff6666; } table.zdp-calendar td { border: 1px solid #666666; text-align: center; } table.zdp-calendar caption { background-color: #333333; padding: 2px; } span.zdp-current-month { display: inline-block; width: auto; height: 16px; padding: 0 2px; line-height: 16px; margin: 0 auto; background-color: #999999; border-radius: 5px; } span.zdp-increase-month, span.zdp-increase-year, span.z...
EventTarget.addEventListener() - Web APIs
WebAPIEventTargetaddEventListener
legacy internet explorer and attachevent in internet explorer versions before ie 9, you have to use attachevent(), rather than the standard addeventlistener().
... for ie, we modify the preceding example to: if (el.addeventlistener) { el.addeventlistener('click', modifytext, false); } else if (el.attachevent) { el.attachevent('onclick', modifytext); } there is a drawback to attachevent(): the value of this will be a reference to the window object, instead of the element on which it was fired.
... the attachevent() method could be paired with the onresize event to detect when certain elements in a web page were resized.
....target=e.srcelement; e.currenttarget=self; if (typeof listener.handleevent != 'undefined') { listener.handleevent(e); } else { listener.call(self,e); } }; if (type=="domcontentloaded") { var wrapper2=function(e) { if (document.readystate=="complete") { wrapper(e); } }; document.attachevent("onreadystatechange",wrapper2); eventlisteners.push({object:this,type:type,listener:listener,wrapper:wrapper2}); if (document.readystate=="complete") { var e=new event(); e.srcelement=window; wrapper2(e); } } else { this.attachevent("on"+type,wrapper); eventlisteners.push({object:this,type:type,listener:listener,wrapper:...
jspage - Archive of obsolete content
ArchiveMozillaJetpackjspage
:"window"}}; new window(window);var document=new native({name:"document",legacy:(browser.engine.trident)?null:window.document,initialize:function(a){$uid(a);a.head=a.getelementsbytagname("head")[0]; a.html=a.getelementsbytagname("html")[0];if(browser.engine.trident&&browser.engine.version<=4){$try(function(){a.execcommand("backgroundimagecache",false,true); });}if(browser.engine.trident){a.window.attachevent("onunload",function(){a.window.detachevent("onunload",arguments.callee);a.head=a.html=a.window=null; });}return $extend(a,document.prototype);},afterimplement:function(b,a){document[b]=document.prototype[b]=a;}});document.prototype={$family:{name:"document"}}; new document(document);array.implement({every:function(c,d){for(var b=0,a=this.length;b<a;b++){if(!c.call(d,this[b],b,this)){return false;...
...s.contains)?(this!=l&&this.contains(l)):!!(this.comparedocumentposition(l)&16); },match:function(l){return(!l||(l==this)||(element.get(this,"tag")==l));}});native.implement([element,window,document],{addlistener:function(o,n){if(o=="unload"){var l=n,m=this; n=function(){m.removelistener("unload",n);l();};}else{h[this.uid]=this;}if(this.addeventlistener){this.addeventlistener(o,n,false);}else{this.attachevent("on"+o,n); }return this;},removelistener:function(m,l){if(this.removeeventlistener){this.removeeventlistener(m,l,false);}else{this.detachevent("on"+m,l);}return this; },retrieve:function(m,l){var o=c(this.uid),n=o[m];if(l!=undefined&&n==undefined){n=o[m]=l;}return $pick(n);},store:function(m,l){var n=c(this.uid);n[m]=l; return this;},eliminate:function(l){var m=c(this.uid);delete m[l];return this...
Migrate apps from Internet Explorer to Mozilla - Archive of obsolete content
ArchiveMozillaMigrate apps from Internet Explorer to Mozilla
it also does not support the attachevent and detachevent methods.
...event method differences between mozilla and internet explorer internet explorer method mozilla method description attachevent(aeventtype, afunctionreference) addeventlistener(aeventtype, afunctionreference, ausecapture) adds an event listener to a dom element.
Ajax navigation example - Web APIs
WebAPIHistory APIExample
addeventlistener("load", init, false) : window.attachevent ?
... attachevent("onload", init) : (onload = init); // public methods this.open = requestpage; this.stop = abortreq; this.rebuildlinks = init; })(); for more information, please see: working with the history api.
Index - Web APIs
WebAPIIndex
1275 eventtarget.addeventlistener() api, accessouterdata, dom, detecting events, event handlers, event listener, eventtarget, javascript, method, passingdata, receiving events, reference, addeventlistener, attachevent, events, mselementresize the eventtarget method addeventlistener() sets up a function that will be called whenever the specified event is delivered to the target.
... 1276 eventtarget.attachevent() no summary!
Events and the DOM - Web APIs
WebAPIDocument Object ModelEvents
note: internet explorer 6–8 didn't support this method, offering a similar eventtarget.attachevent api instead.
Element.classList - Web APIs
WebAPIElementclassList
}); defineproperty(ele, " uclp", { // for accessing the hidden prototype enumerable: 0, configurable: 0, writeable: 0, value: protoobj.prototype }); defineproperty(protoobjproto, " ucl", { enumerable: 0, configurable: 0, writeable: 0, value: ele }); } else { ele.classlist=restokenlist, ele[" ucl"]=restokenlist, ele[" uclp"]=protoobj.prototype; } ele.attachevent( "onpropertychange", whenpropchanges ); } try { // much faster & cleaner version for ie8 & ie9: // should work in ie8 because element.prototype instanceof node is true according to the specs window.object.defineproperty(window.element.prototype, "classlist", { enumerable: 1, get: function(val){ if (!hasownprop.call(this, "clas...
onMSVideoFormatChanged - Web APIs
WebAPIHTMLVideoElementonMSVideoFormatChanged
syntax value description event property object.onmsvideoformatchanged = handler; attachevent method object.attachevent("onmsvideoformatchanged", handler) addeventlistener method object.addeventlistener("", handler, usecapture) event handler parameters val[in], type=function see also htmlvideoelement microsoft api extensions ...
onMSVideoFrameStepCompleted - Web APIs
WebAPIHTMLVideoElementonMSVideoFrameStepCompleted
syntax value description event property object.onmsvideoframestepcompleted = handler; attachevent method object.attachevent("onmsvideoframestepcompleted", handler) addeventlistener method object.addeventlistener("", handler, usecapture) event handler parameters val[in], type=function see also htmlvideoelement microsoft api extensions ...
onMSVideoOptimalLayoutChanged - Web APIs
WebAPIHTMLVideoElementonMSVideoOptimalLayoutChanged
syntax value description event property object.onmsvideooptimallayoutchanged = handler; attachevent method object.attachevent("onmsvideooptimallayoutchanged", handler) addeventlistener method object.addeventlistener("", handler, usecapture) synchronous no bubbles no cancelable no see also msislayoutoptimalforplayback htmlvideoelement microsoft api extensions ...
window.location - Web APIs
WebAPIWindowlocation
th.round(_scrollx + (_nodex - _scrollx) * _itframe / nframes); if (_usehash && _itframe === nframes) { location.hash = _bookmark; } _itframe++; } function _chkowner () { if (_isbot) { _isbot = false; return; } if (_scrollid > -1) { clearinterval(_scrollid); _scrollid = -1; } } if (window.addeventlistener) { window.addeventlistener("scroll", _chkowner, false); } else if (window.attachevent) { window.attachevent("onscroll", _chkowner); } return function (sbookmark, busehash) { var onode = document.queryselector(sbookmark); _scrolly = document.documentelement.scrolltop; _scrollx = document.documentelement.scrollleft; _bookmark = sbookmark; _usehash = busehash === true; _nodex = onode.offsetleft; _nodey = onode.offsettop; _itframe = 1; if (_scrollid === -1) ...