//Comment trail script- By Kurt (kurt.grigg@virgin.net)
//Script featured on Dynamic Drive
//Visit http://www.dynamicdrive.com for this script and more

colours=new Array('#ff0000','#00ff00','#ffffff','#ff00ff','#ffa500','#ffff00','#00ff00','#ffffff','ff00ff')
nc = 10;
yc = 0;
xc = 0;
n6=(document.getElementById&&!document.all);
ns=(document.layers);
ie=(document.all);
dc=(ns||ie)?'document.':'document.getElementById("';
ac=(ns||n6)?'':'all.';
n6r=(n6)?'")':'';
sc=(ns)?'':'.style';
if (ns){
for (ic = 0; ic < nc; i++)
document.write('<layer name="dots'+ic+'" top=0 left=0 width='+ic/2+' height='+ic/2+' bgcolor=#ff0000></layer>');
}
if (ie)
document.write('<div id="con" style="position:absolute;top:0px;left:0px"><div style="position:relative">');
if (ie||n6){
for (ic = 0; ic < nc; ic++)
document.write('<div id="dots'+ic+'" style="position:absolute;top:0px;left:0px;width:'+ic/2+'px;height:'+ic/2+'px;background:#ff0000;font-size:'+ic/2+'"></div>');
}
if (ie)
document.write('</div></div>');
(ns||n6)?window.captureEvents(Event.MOUSEMOVE):0;
function Mouse(evnt){
yc = (ns||n6)?evnt.pageY+4 - window.pageYOffset:event.y+4;
xc = (ns||n6)?evnt.pageX+1:event.x+1;
}
(ns)?window.onMouseMove=Mouse:document.onmousemove=Mouse;
function animate(){
oc=(ns||n6)?window.pageYOffset:0;
if (ie)document.getElementById("con").style.top=document.body.scrollTop;
for (ic = 0; ic < nc; ic++){
var temp1 = eval(dc+ac+"dots"+ic+n6r+sc);
randcolours = colours[Math.floor(Math.random()*colours.length)];
(ns)?temp1.bgColor = randcolours:temp1.background = randcolours; 
if (ic < nc-1){
 var temp2 = eval(dc+ac+"dots"+(ic+1)+n6r+sc);
 temp1.top = parseInt(temp2.top);
 temp1.left = parseInt(temp2.left);
 } 
else{
 temp1.top = yc+oc;
 temp1.left = xc;
 }
}
setTimeout("animate()",10);
}
animate();