Fixed a time bug
authorRuss Handorf <rhandorf@handorf.org>
Tue, 24 May 2016 03:53:33 +0000 (23:53 -0400)
committerRuss Handorf <rhandorf@handorf.org>
Tue, 24 May 2016 03:53:33 +0000 (23:53 -0400)
php/index.php

index 396204f..cb52d19 100644 (file)
@@ -190,9 +190,9 @@ function get_time() {
 
 function update_time() {
   ntpcounter=ntpcounter+1;
-  date.setSeconds(date.getSeconds() + 1);
   document.getElementById("updatetime").innerHTML = (date);
-  if (ntpcounter>3600) {
+  date.setSeconds(date.getSeconds() + 1);
+  if (ntpcounter>600) {
     ntpcounter=0;
     get_time();
   }