in <head>
<script type="text/javascript"> //change your event date event here. var eventdate = new Date("May 11, 2006 18:00:00 GMT"); function toSt(n) {s="" if(n<10) s+="0" return s+n.toString(); } function countdown() {cl=document.clock; d=new Date(); count=Math.floor((eventdate.getTime()-d.getTime())/1000); if(count<=0) {cl.days.value ="--"; cl.hours.value="--"; cl.mins.value="--"; cl.secs.value="--"; return; } cl.secs.value=toSt(count%60); count=Math.floor(count/60); cl.mins.value=toSt(count%60); count=Math.floor(count/60); cl.hours.value=toSt(count%24); count=Math.floor(count/24); cl.days.value=count; setTimeout("countdown()",500); } </script>
and in <body>
<form name="clock" action="none"> <input name="days" size="1" /> Days, <input name="hours" size="1" /> Hours, <input name="mins" size="1" /> Minutes, and <input name="secs" size="1" /> seconds. </form>
Thanks in advance for any help.
-Ryan
Edited by rmurphy, 22 April 2006 - 12:12 AM.