-1

What i need is a javascript countdown clock that will start everyday at 7:40am and end at 2:15pm. But when it ends at 2:15pm i need it to auto restart at 7:40 am.

ryan
  • 1
  • 1

1 Answers1

0
<script type="text/javascript" src="jquery.js"></script>

// 6 hours and 45 minutes
iMilliseconds = 6 * 60 * 60 * 1000 + 45 * 60 * 1000;

function Restart()
{
 Start();
 setTimeout(iMilliseconds, Restart);
}


function Start()
{
 // Do things
}

$(document).ready(function()
 {
 Restart(); 
});
Daniel Protopopov
  • 6,778
  • 3
  • 23
  • 39