Results 1 to 2 of 2

Thread: Snow effect working in E5+ and not in FF

  1. #1
    Join Date
    Sep 2004
    Posts
    19
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Snow effect working in E5+ and not in FF

    Hi,

    I copy paste the snow effect from Dynamics Drive Forums in my webpage.
    This is working fine if viewed with explorer but not with firefox.

    What do I have to do?

    Thanks

    webpage is
    www.westvlaamsescootervrienden.be

    Regards
    Alain
    Last edited by ostcalling; 10-14-2008 at 05:47 AM.

  2. #2
    Join Date
    Jul 2006
    Posts
    497
    Thanks
    8
    Thanked 70 Times in 70 Posts

    Default

    From the Firefox Error Console (Tools > Error Console):
    Code:
    Error: document.getElementById("dot" + i) is null
    Source File: http://users.skynet.be/osty/scootervrienden/
    Line: 618
    For some reason, lines 598-602 apparently have no effect, although they are running (according to Firebug).
    Code:
    if (i == 0) {
        document.write("<div id=\"dot"+ i +"\" style=\"POSITION: absolute; Z-INDEX: "+ i +"; VISIBILITY: visible; TOP: 15px; LEFT: 15px;\"><a href=\"http://dynamicdrive.com\"><img src='"+snowsrc+"' border=\"0\"><\/a><\/div>");
    } else {
        document.write("<div id=\"dot"+ i +"\" style=\"POSITION: absolute; Z-INDEX: "+ i +"; VISIBILITY: visible; TOP: 15px; LEFT: 15px;\"><img src='"+snowsrc+"' border=\"0\"><\/div>");
    }
    By the way, I'm suspicious of using the same id attribute value in multiple elements. I think it should be name.
    Last edited by Jesdisciple; 10-14-2008 at 06:15 PM.
    -- Chris
    informal JavaScript student of Douglas Crockford
    I like wikis - a lot.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •