function calcage(secs, num1, num2, addDay, seconds) { if (addDay == 1){ s = ((Math.floor(secs/num1))).toString(); } else{ s = ((Math.floor(secs/num1))%num2).toString(); } if (LeadingZeros31250 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks31250(secs) { if (secs < 0) { document.getElementById("cntdwns31250").innerHTML = FinishMessages31250; return; } DisplayStrs31250 = DisplayFormats31250.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs31250 = DisplayStrs31250.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs31250 = DisplayStrs31250.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs31250 = DisplayStrs31250.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns31250").innerHTML = DisplayStrs31250; if (CountActives31250) //alert(SetTimeOutPeriods31250); setTimeout("CountBacks31250(" + (secs+CountSteppers31250) + ")", SetTimeOutPeriods31250); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors31250)=="undefined") BackColors31250 = ""; if (typeof(ForeColors31250)=="undefined") ForeColors31250= "white"; if (typeof(TargetDates31250)=="undefined") TargetDates31250 = "11/14/2024 8:00:00 PM"; if (typeof(DisplayFormats31250)=="undefined") DisplayFormats31250 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives31250)=="undefined") CountActives31250 = true; if (typeof(FinishMessages31250)=="undefined") FinishMessages31250 = ""; if (typeof(CountSteppers31250)!="number") CountSteppers31250 = -1; if (typeof(LeadingZeros31250)=="undefined") LeadingZeros31250 = true; CountSteppers31250 = Math.ceil(CountSteppers31250); if (CountSteppers31250 == 0) CountActives31250 = false; var SetTimeOutPeriods31250 = (Math.abs(CountSteppers31250)-1)*1000 + 990; puti(BackColors31250, ForeColors31250); var dthens31250 = new Date(TargetDates31250); var dnows31250 = new Date("11/13/2024 2:09:10 AM"); if(CountSteppers31250>0) ddiffs31250 = new Date(dnows31250-dthens31250); else ddiffs31250 = new Date(dthens31250-dnows31250); gsecss31250 = Math.floor(ddiffs31250.valueOf()/1000); CountBacks31250(gsecss31250);