Is it possible to have multiple images falling, ie snowflakes AND Christmas puddings??!!
I am a complete novice at javascript....!
Thanks
Shona :cool:
Is it possible to have multiple images falling, ie snowflakes AND Christmas puddings??!!
I am a complete novice at javascript....!
Thanks
Shona :cool:
Its an oldie, but maybe this - you can specify different images in the script array: http://www.dynamicdrive.com/dynamicindex3/leaves.htm
Dont go too crazy with the number of images though or it can really slow things down.
Ah perfect! thanks! (how do i slow down the speed a little?!!) i have used three images, and they are whizzing down the page!
See " setTimeout('fall()',20); " on one of the last lines?
Change the value to about 40, like this;
I think a speed of 40-50 looks most "snowy".Code:setTimeout('fall()',40);
thanks! thats slowed it down a bit.
I have copied it into the body of my index.html page now but it doesnt work! i just get the three images on top of one another in top left corner...! http://www.frasersauctionroom.co.uk/
Have you sussed it?
I just checked and its working fine in IE9, Chrome and Firefox.
My mistake - it looks like there is another 'pudding' script in there instead.
Try taking that out and only using the slowed-down leaves one.
Scratch that - its down to the DOCTYPE.
It looks like this old script wont work with valid DOCTYPES - just a <html> tag.
i have used a completely different script, and have two different images falling now by amending this part:
(someone else showed me how to though, i have no clue about javascript really!)Code:for (i = 0; i < no; ++ i) {
if(i % 2) {
snowsrc="christmas-pudding.gif";
} else {
snowsrc="snow3.gif";
}
I just clicked on the link and it works fine for me using ff 16.0.2