/* Cursor Trailor Text- By Peter Gehrig (http://www.24fun.com/) */
var x = 0, y = 0;
var step = 20;
var flag = 0;
var message = "ضع هنا الكلمة";
message = message.split("");
var xpos = new Array();
for (i=0; i{
xpos[i]=-50;
}
var ypos = new Array();
for (i=0; i{
ypos[i]=-50;
}
function handlerMM(e)
{
if (!e)
var e = window.event||window.Event;
if ('undefined' != typeof e.pageX)
{
x = e.pageX;
y = e.pageY;
}
else
{
x = e.clientX + document.body.scrollLeft;
y = e.clientY + document.body.scrollTop;
}
flag=1;
}
function makesnake()
{
for (i=message.length-1; i>=1; i--)
{
xpos[i] = xpos[i-1] + step;
ypos[i] = ypos[i-1];
}
xpos[0] = x + step;
ypos[0] = y;
for (i=0; i {
var id = 'span'+i;
var thisspan = document.getElementById(id);
thisspan.style.left = xpos[i] + "px";
thisspan.style.top = ypos[i] + "px";
}
var timer=setTimeout("makesnake()",30);
}
for (i=0;i<=message.length-1;i++)
{
document.write("");
document.write(message[i]);
document.write("");
}
if (document.layers)
{
document.captureEvents(Event.MOUSEMOVE);
}
document.onmousemove = handlerMM;
makesnake();