Firefox freezes if I change my system clock

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • daniel2335
    New Member
    • Dec 2007
    • 49

    #1

    Firefox freezes if I change my system clock

    When running the simplest javascript in firefox I get a freeze if I change my system clock.
    Not sure if this is a javascript problem with setInterval call or a firefox problem.

    The code I used was:
    Code:
    <html>
    <head>
    <script type="text/javascript">
       setInterval('test1()', 500);
       var inc = 0;
       function test1()
       {
          inc += 1;
          document.getElementById('id1').innerHTML = inc;
       }
    </script>
    </head>
    <body id="id1">
    </body>
    </html>
    If you run that in firefox so that its incrementing then change your system clock up and down by an hour it should freeze.
    Can anyone make sence of this?

    Thanks
  • daniel2335
    New Member
    • Dec 2007
    • 49

    #2
    Well to answer my own question.. I thought maybe it was to do with the setInterval so I changed my search. Managed to find an article with people suggesting the use of setTimeout of setInterval. Seems to have worked.

    Comment

    Working...