This is a cool useless trick made with javascript. Copy and paste the following piece of code into the URL box of your browser and enjoy (tested on firefox and chrome):
javascript:already_falling=false;img=document.getElementById('falling_object');if (img) already_falling=true;if (!already_falling){img=document.createElement('IMG');document.body.appendChild(img);}brwidth=document.all?document.body.clientWidth:window.innerWidth; brheight=document.all?document.body.clientHeight:window.innerHeight; var randomLeft=Math.floor(Math.random()*(brwidth-img.clientWidth));img.setAttribute('id','falling_object');img.setAttribute('src','http://img9.imageshack.us/img9/5761/ballrq.png');imgst=img.style;imgst.position='fixed';imgst.zIndex=10000;imgst.left=randomLeft+'px';imgst.top='0px';dx=14*(Math.random()>0.5?-1:1);dy=0;function fall(){dy+=2;imgst.left=(parseInt(imgst.left)+dx)+"px";imgst.top=(parseInt(imgst.top)+dy)+"px";if (dx<0 && parseInt(imgst.left)<=0){imgst.left='0px';dx*=-1;dx-=2;}else if (dx>0 && parseInt(imgst.left)+img.clientWidth>=brwidth){imgst.left=(brwidth-img.clientWidth)+'px';dx*=-1;dx+=2;}if (parseInt(imgst.top)+img.clientHeight>=brheight){imgst.top=(brheight-img.clientHeight)+'px';dy*=-1;if (dx>0) dx-=0.2;else if (dx<0) dx+=0.2;if (Math.abs(dx)<0.2) dx=0;}}if (!already_falling) fallinterval=setInterval('fall()',15);void(0);


Sign In
Create Account

Back to top









