PDA

View Full Version : Dancing Stars Cursor Modification



danielck
03-31-2005, 02:36 AM
Hi,

I would like to know if it is possible to modify this script so that the cursor trail will automatically fade out after X seconds:

http://dynamicdrive.com/dynamicindex13/star.htm

Thanks in advance!

jscheuer1
03-31-2005, 09:46 AM
Well, first of all be aware that this script doesn't work in modern Mozilla browsers like FireFox and Netscape to begin with. It does work in IE and older Netscape browsers. I can modify it to stop, fading out would be another matter entirely, maybe for the IE5+ part. Anyways, try this, where it says:
function animateLogo() {make it look like this:
x=0
function animateLogo() {
x+=1and where it says:
setTimeout("animateLogo()", 15);make it look like this:
if (x>=8*75){ // change 8 to approx. number of seconds before effect ends
if(document.all)document.all('starsDiv').style.display='none';
else{
for (i = 0; i < 7; i++)
document.layers['a'+i].visibility='hide'}
clearTimeout(astars);}
else
astars=setTimeout("animateLogo()", 15);for an effect that ends after about 8 seconds.

danielck
04-15-2005, 01:36 AM
Thank you for your help :) It works