![]()
Snippets of A |
|
|
What are snippets? |
|
function offRL(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offRL"; object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetWidth/2; onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || 0; object['stop2']=parseFloat(stop2) || object['layer'].offsetHeight; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.right -= (this.right - this.amount>=this.stop1)? this.amount:(this.stop1==0)?this.right: (this.right - this.stop1>0)?(this.right - this.stop1): Math.abs(this.right - this.stop1); this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.right <= this.stop1){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function offRL2(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offRL2"; object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetWidth/2; onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || object['layer'].offsetWidth/2; object['stop2']=parseFloat(stop2) || object['layer'].offsetWidth/2; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.right -= (this.right - this.amount>=this.stop1)? this.amount:(this.stop1==0)?this.right: (this.right - this.stop1>0)?(this.right - this.stop1): Math.abs(this.right - this.stop1); // this.left += (this.left + this.amount<=this.stop2)? this.amount:(this.stop2==this.layer.offsetWidth)?(this.stop2 - this.left): (this.stop2 - this.left>0)?(this.stop2 - this.left):0; this.setClip( [this.top, this.right, this.bottom, this.left] ); //this.layer.style.left = this.originalLeft + (this.layer.offsetWidth - this.getClip()[1]); //EXIT CONDITION: if(this.right <= this.stop1 || this.left>=this.stop2){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function offLR(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offLR";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetWidth/2;// onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || object['layer'].offsetWidth; object['stop2']=parseFloat(stop2) || object['layer'].offsetHeight; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.left += (this.left + this.amount<=this.stop1)? this.amount:(this.stop1==this.layer.offsetWidth)?(this.stop1 - this.left): (this.stop1 - this.left>0)?(this.stop1 - this.left):0; this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.left >= this.stop1){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function offTB(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offTB";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetHeight/2;// onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || object['layer'].offsetWidth; object['stop2']=parseFloat(stop2) || object['layer'].offsetHeight; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.top += (this.top + this.amount<=this.stop2)? this.amount:(this.stop2==this.layer.offsetHeight)?(this.stop2 - this.top): (this.stop2 - this.top>0)?(this.stop2 - this.top):0; this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.top >= this.stop2){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function offTB2(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offTB2";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetHeight/2;// onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || object['layer'].offsetHeight/2; object['stop2']=parseFloat(stop2) || object['layer'].offsetHeight/2; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.top += (this.top + this.amount<=this.stop2)? this.amount:(this.stop2==this.layer.offsetHeight)?(this.stop2 - this.top): (this.stop2 - this.top>0)?(this.stop2 - this.top):0; // this.bottom -= (this.bottom - this.amount>=this.stop1)? this.amount:(this.stop1==0)?this.bottom: (this.bottom - this.stop1>0)?(this.bottom - this.stop1): Math.abs(this.bottom - this.stop1); this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.top >= this.stop2 || this.bottom<=this.stop1){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function offBT(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offBT";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetHeight/2; onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || object['layer'].offsetWidth; object['stop2']=parseFloat(stop2) || 0; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.bottom -= (this.bottom - this.amount>=this.stop2)? this.amount:(this.stop2==0)?this.bottom: (this.bottom - this.stop2>0)?(this.bottom - this.stop2): Math.abs(this.bottom - this.stop2); this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.bottom <= this.stop2){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function offBTRL(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offBTRL";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetHeight/2; onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || 0; object['stop2']=parseFloat(stop2) || 0; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['amount2']=object['amount']*object['layer'].offsetWidth/object['layer'].offsetHeight; object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.bottom-=(this.bottom-this.amount>=this.stop2)? this.amount:(this.stop2==0)?this.bottom: (this.bottom-this.stop2>0)?(this.bottom-this.stop2): Math.abs(this.bottom-this.stop2); // this.right-=(this.right-this.amount2>=this.stop1)? this.amount2:(this.stop1==0)?this.right: (this.right-this.stop1>0)?(this.right-this.stop1): Math.abs(this.right-this.stop1); this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.bottom <= this.stop2 || this.right <= this.stop1){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function offTBRL(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offTBRL";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetHeight/2; onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || 0; object['stop2']=parseFloat(stop2) || object['layer'].offsetHeight; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['amount2']=object['amount']*object['layer'].offsetWidth/object['layer'].offsetHeight; object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.top += (this.top + this.amount<=this.stop2)? this.amount:(this.stop2==this.layer.offsetHeight)?(this.stop2 - this.top): (this.stop2 - this.top>0)?(this.stop2 - this.top):0; // this.right-=(this.right-this.amount2>=this.stop1)? this.amount2:(this.stop1==0)?this.right: (this.right-this.stop1>0)?(this.right-this.stop1): Math.abs(this.right-this.stop1); this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.top >= this.stop2 || this.right <= this.stop1){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function offTBLR(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offTBLR";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetHeight/2; onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || object['layer'].offsetWidth; object['stop2']=parseFloat(stop2) || object['layer'].offsetHeight; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['amount2']=object['amount']*object['layer'].offsetWidth/object['layer'].offsetHeight; object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.top += (this.top + this.amount<=this.stop2)? this.amount:(this.stop2==this.layer.offsetHeight)?(this.stop2 - this.top): (this.stop2 - this.top>0)?(this.stop2 - this.top):0; // this.left += (this.left + this.amount2<=this.stop1)? this.amount2:(this.stop1==this.layer.offsetWidth)?(this.stop1 - this.left): (this.stop1 - this.left>0)?(this.stop1 - this.left):0; this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.top >= this.stop2 || this.left >= this.stop1){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function offBTLR(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offBTLR";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetHeight/2; onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || object['layer'].offsetWidth; object['stop2']=parseFloat(stop2) || 0; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['amount2']=object['amount']*object['layer'].offsetWidth/object['layer'].offsetHeight; object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.bottom -= (this.bottom - this.amount>=this.stop2)? this.amount:(this.stop2==0)?this.bottom: (this.bottom - this.stop2>0)?(this.bottom - this.stop2): Math.abs(this.bottom - this.stop2); // this.left += (this.left + this.amount2<=this.stop1)? this.amount2:(this.stop1==this.layer.offsetWidth)?(this.stop1 - this.left): (this.stop1 - this.left>0)?(this.stop1 - this.left):0; this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.bottom <= this.stop2 || this.left >= this.stop1){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function offAll(id, speed, amount, size, onExitOptionalFunction, stop1, stop2, stop3, stop4){ if(id){ /*Warning: since it clips ALL, the stop parameters (IF passed) should be passed as an HALF of the meant values: in fact the layer is clipped BOTH from TOP and BOTTOM in its height, and BOTH from LEFT and RIGHT in its width, so values are halved.*/ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offAll";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetHeight/2; onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || object['layer'].offsetWidth / 2; object['stop2']=parseFloat(stop2) || object['layer'].offsetHeight / 2; object['stop3']=parseFloat(stop3) || 0; object['stop4']=parseFloat(stop4) || 0; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['amount2']=object['amount']*object['layer'].offsetWidth/object['layer'].offsetHeight; object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.left += (this.left + this.amount2<=this.stop1)? this.amount2:(this.stop1==this.layer.offsetWidth)?(this.stop1 - this.left): (this.stop1 - this.left>0)?(this.stop1 - this.left):0; // this.top += (this.top + this.amount<=this.stop2)? this.amount:(this.stop2==this.layer.offsetHeight)?(this.stop2 - this.top): (this.stop2 - this.top>0)?(this.stop2 - this.top):0; // this.bottom -= (this.bottom - this.amount>=this.stop3)? this.amount:(this.stop3==0)?this.bottom: (this.bottom - this.stop3>0)?(this.bottom - this.stop3): Math.abs(this.bottom - this.stop3); // this.right-=(this.right-this.amount2>=this.stop4)? this.amount2:(this.stop4==0)?this.right: (this.right-this.stop4>0)?(this.right-this.stop4): Math.abs(this.right-this.stop4); this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.top >= this.stop2 || this.left>=this.stop1 || this.bottom <= this.stop3 || this.right <= this.stop4){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function offAll2(id, speed, amount, size, onExitOptionalFunction, stop1, stop2, stop3, stop4){ if(id){ /*Warning: since it clips ALL, the stop parameters (IF passed) should be passed as an HALF of the meant values: in fact the layer is clipped BOTH from TOP and BOTTOM in its height, and BOTH from LEFT and RIGHT in its width, so values are halved.*/ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="offAll2";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetHeight/2; onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || object['layer'].offsetWidth / 2; object['stop2']=parseFloat(stop2) || object['layer'].offsetHeight / 2; object['stop3']=parseFloat(stop3) || 0; object['stop4']=parseFloat(stop4) || 0; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['amount2']=object['amount']//*object['layer'].offsetHeight/object['layer'].offsetWidth; object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.left += (this.left + this.amount2<=this.stop1)? this.amount2:(this.stop1==this.layer.offsetWidth)?(this.stop1 - this.left): (this.stop1 - this.left>0)?(this.stop1 - this.left):0; // this.top += (this.top + this.amount<=this.stop2)? this.amount:(this.stop2==this.layer.offsetHeight)?(this.stop2 - this.top): (this.stop2 - this.top>0)?(this.stop2 - this.top):0; // this.bottom -= (this.bottom - this.amount>=this.stop3)? this.amount:(this.stop3==0)?this.bottom: (this.bottom - this.stop3>0)?(this.bottom - this.stop3): Math.abs(this.bottom - this.stop3); // this.right-=(this.right-this.amount2>=this.stop4)? this.amount2:(this.stop4==0)?this.right: (this.right-this.stop4>0)?(this.right-this.stop4): Math.abs(this.right-this.stop4); this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.top >= this.stop2 || this.left>=this.stop1 || this.bottom <= this.stop3 || this.right <= this.stop4){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function onTB(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="onTB";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetHeight/2;// onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || object['layer'].offsetWidth; object['stop2']=parseFloat(stop2) || object['layer'].offsetHeight; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=0;//object['originalClip'][2*]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.bottom+=(this.bottom+this.amount<=this.stop2)? this.amount:(this.stop2==this.layer.offsetHeight)?(this.stop2-this.bottom): (this.stop2-this.bottom>0)?(this.stop2-this.bottom):0; this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.bottom >= this.stop2){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */} function onTB2(id, speed, amount, size, onExitOptionalFunction, stop1, stop2){ if(id){ id=(typeof(id)=="object")? id.id: id; var variableName=id+"_clipper"; if(window[variableName] && window[variableName].isRunning){return;}; if(!id || !document.getElementById(id)){return;}; var object=window[variableName]=new Object(); object['layer']=document.getElementById(id); object["id"]=id; var name="onTB2";// object[name]=window[name]; object["last"]=name; object.isRunning=1; object['speed']=parseFloat(speed) || 100; object['amount']=parseFloat(amount) || 1; object['size']=parseFloat(size) || object['layer'].offsetHeight/2;// onExitOptionalFunction=(typeof(onExitOptionalFunction)=="string")? window[onExitOptionalFunction]:onExitOptionalFunction; object['onExitOptionalFunction']=(typeof(onExitOptionalFunction)=="function")? onExitOptionalFunction:(onExitOptionalFunction/*==1*/)? function(object){ document.getElementById( object.id ).style.visibility="hidden"; object.setClip(object.originalClip); } :0; object['stop1']=parseFloat(stop1) || 0//object['layer'].offsetHeight/2; object['stop2']=parseFloat(stop2) || object['layer'].offsetHeight; object['timer']=null; object["stop"]=function(){ clearInterval(this.timer); this.isRunning=0; if(typeof(this.onExitOptionalFunction)=="function"){this.onExitOptionalFunction(this);}; } object["setClip"]= function(array){ if(typeof(array)=="string"){array=array.match(/\d+/g);} var output="rect("; for(var a=0; a<array.length; a++){output+=array[a]+"px, ";} this.layer.style.clip=output.substring(0, output.length - 2)+")"; }; object["getClip"]= function(){ if(!this.layer.style.clip){ this.layer.style.clip= "rect(0px, "+ parseFloat(this.layer.offsetWidth)+"px, "+ parseFloat(this.layer.offsetHeight) + "px, 0px)"; }; var clip=this.layer.style.clip.replace(/(^\s*rect\s*\()|(\)\s*$)/g,'').replace(/\s+/g," ").split(" "); return [parseFloat(clip[0]), parseFloat(clip[1]), parseFloat(clip[2]), parseFloat(clip[3])]; }; object['layer'].style.position="absolute"; object['layer'].style.visibility="visible"; object["originalTop"]=object['layer'].offsetTop; object["originalLeft"]=object['layer'].offsetLeft; object['originalClip']=object.getClip(); object['top']=object['layer'].offsetHeight/2;//object['originalClip'][0]; object['right']=object['originalClip'][1]; object['bottom']=object['layer'].offsetHeight/2;//object['originalClip'][2]; object['left']=object['originalClip'][3]; object.setClip([ object['top'], object['right'], object['bottom'], object['left'] ]); object['timer']=setInterval( variableName+"."+name+"()", object['speed'] ); return 0; }; //RUNTIME: this.top-=(this.top-this.amount>=this.stop1)? this.amount:(this.stop1==0)?this.top: (this.stop1-this.top>0)?(this.stop1-this.top): Math.abs(this.stop1-this.top); // this.bottom+=(this.bottom+this.amount<=this.stop2)? this.amount:(this.stop2==this.layer.offsetHeight)?(this.stop2-this.bottom): (this.stop2-this.bottom>0)?(this.stop2-this.bottom):0; this.setClip( [this.top, this.right, this.bottom, this.left] ); //EXIT CONDITION: if(this.top <= this.stop1 || this.bottom >= this.stop2){ this.stop(); }; /*keep this comment to reuse freely http://www.fullposter.com/?1 */}Remove colors