1 wiper and cursor(text) Tue Nov 18, 2008 10:16 am
yanyan025
Guest
<!--
//set message:
msg = "EDIT HERE";
timeID = 10;
stcnt = 16;
wmsg = new Array(33);
wmsg[0]=msg;
blnk = " ";
for (i=1; i<32; i++)
{
b = blnk.substring(0,i);
wmsg[i]="";
for (j=0; j<msg.length; j++) wmsg[i]=wmsg[i]+msg.charAt(j)+b;
}
function wiper()
{
if (stcnt > -1) str = wmsg[stcnt]; else str = wmsg[0];
if (stcnt-- < -40) stcnt=31;
status = str;
clearTimeout(timeID);
timeID = setTimeout("wiper()",100);
}
wiper()
// -->
Complite sa JS ext..
CURSOR(text)
var text='<font color="#FFFFFF"><b>edit here</b></font>';
var echocount=5; // NUMBER OF TEXT "ECHO"S
var delay=75; // SPEED OF TRAIL
var Xoff=10; // AMOUNT OF PIXELS TO THE RIGHT IMAGE WILL BE AWAY FROM CURSOR (- VALUES GO TO LEFT)
var Yoff=30; // AMOUNT OF PIXELS TO THE BOTTOM IMAGE WILL BE AWAY FROM CURSOR (- VALUES GO UP)
//********** NO NEED TO EDIT BELOW HERE **********\\
ns4 = (navigator.appName.indexOf("Netscape")>=0 && document.layers)? true : false;
ie4 = (document.all && !document.getElementById)? true : false;
ie5 = (document.all && document.getElementById)? true : false;
ns6 = (document.getElementById && navigator.appName.indexOf("Netscape")>=0 )? true: false;
var txtA=new Array();
var x1=0;
var y1=-1000;
var t='';
for(i=1;i<=echocount;i++){
t+=(ns4)? '<layer name="txt'+i+'" top="-1000" left="0" width="1" height="1">' : '<div id="txt'+i+'" style="position:absolute; top:-1000px; left:0px; width:1px; height:1px; visibility:visible">';
t+='<table cellspacing="0" cellpadding="0" border="0"><tr><td nowrap>'+text+'</td></tr></table>';
t+=(ns4)? '</layer>' : '</div>';
}
document.write(t);
function moveid(id,x,y){
if(ns4)id.moveTo(x,y);
else{
id.style.left=x+'px';
id.style.top=y+'px';
}}
function animate(evt){
x1=Xoff+((ie4||ie5)?event.clientX+document.body.scrollLeft:evt.pageX);
y1=Yoff+((ie4||ie5)?event.clientY+document.body.scrollTop:evt.pageY);
}
function movetxts(){
for(i=echocount;i>1;i=i-1)moveid(txtA[i], (ns4)?txtA[i-1].left:parseInt(txtA[i-1].style.left), (ns4)?txtA[i-1].top:parseInt(txtA[i-1].style.top));
moveid(txtA[1],x1,y1);
}
window.onload=function(){
for(i=1;i<=echocount;i++)txtA[i]=(ns4)?document.layers['txt'+i]:(ie4)?document.all['txt'+i]:document.getElementById('txt'+i);
if(ns4)document.captureEvents(Event.MOUSEMOVE);
document.onmousemove=animate;
setInterval('movetxts()',delay);
}
//set message:
msg = "EDIT HERE";
timeID = 10;
stcnt = 16;
wmsg = new Array(33);
wmsg[0]=msg;
blnk = " ";
for (i=1; i<32; i++)
{
b = blnk.substring(0,i);
wmsg[i]="";
for (j=0; j<msg.length; j++) wmsg[i]=wmsg[i]+msg.charAt(j)+b;
}
function wiper()
{
if (stcnt > -1) str = wmsg[stcnt]; else str = wmsg[0];
if (stcnt-- < -40) stcnt=31;
status = str;
clearTimeout(timeID);
timeID = setTimeout("wiper()",100);
}
wiper()
// -->
Complite sa JS ext..
CURSOR(text)
var text='<font color="#FFFFFF"><b>edit here</b></font>';
var echocount=5; // NUMBER OF TEXT "ECHO"S
var delay=75; // SPEED OF TRAIL
var Xoff=10; // AMOUNT OF PIXELS TO THE RIGHT IMAGE WILL BE AWAY FROM CURSOR (- VALUES GO TO LEFT)
var Yoff=30; // AMOUNT OF PIXELS TO THE BOTTOM IMAGE WILL BE AWAY FROM CURSOR (- VALUES GO UP)
//********** NO NEED TO EDIT BELOW HERE **********\\
ns4 = (navigator.appName.indexOf("Netscape")>=0 && document.layers)? true : false;
ie4 = (document.all && !document.getElementById)? true : false;
ie5 = (document.all && document.getElementById)? true : false;
ns6 = (document.getElementById && navigator.appName.indexOf("Netscape")>=0 )? true: false;
var txtA=new Array();
var x1=0;
var y1=-1000;
var t='';
for(i=1;i<=echocount;i++){
t+=(ns4)? '<layer name="txt'+i+'" top="-1000" left="0" width="1" height="1">' : '<div id="txt'+i+'" style="position:absolute; top:-1000px; left:0px; width:1px; height:1px; visibility:visible">';
t+='<table cellspacing="0" cellpadding="0" border="0"><tr><td nowrap>'+text+'</td></tr></table>';
t+=(ns4)? '</layer>' : '</div>';
}
document.write(t);
function moveid(id,x,y){
if(ns4)id.moveTo(x,y);
else{
id.style.left=x+'px';
id.style.top=y+'px';
}}
function animate(evt){
x1=Xoff+((ie4||ie5)?event.clientX+document.body.scrollLeft:evt.pageX);
y1=Yoff+((ie4||ie5)?event.clientY+document.body.scrollTop:evt.pageY);
}
function movetxts(){
for(i=echocount;i>1;i=i-1)moveid(txtA[i], (ns4)?txtA[i-1].left:parseInt(txtA[i-1].style.left), (ns4)?txtA[i-1].top:parseInt(txtA[i-1].style.top));
moveid(txtA[1],x1,y1);
}
window.onload=function(){
for(i=1;i<=echocount;i++)txtA[i]=(ns4)?document.layers['txt'+i]:(ie4)?document.all['txt'+i]:document.getElementById('txt'+i);
if(ns4)document.captureEvents(Event.MOUSEMOVE);
document.onmousemove=animate;
setInterval('movetxts()',delay);
}