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 (LeadingZeros29614 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks29614(secs) { if (secs < 0) { document.getElementById("cntdwns29614").innerHTML = FinishMessages29614; return; } DisplayStrs29614 = DisplayFormats29614.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs29614 = DisplayStrs29614.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs29614 = DisplayStrs29614.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs29614 = DisplayStrs29614.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns29614").innerHTML = DisplayStrs29614; if (CountActives29614) //alert(SetTimeOutPeriods29614); setTimeout("CountBacks29614(" + (secs+CountSteppers29614) + ")", SetTimeOutPeriods29614); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors29614)=="undefined") BackColors29614 = ""; if (typeof(ForeColors29614)=="undefined") ForeColors29614= "white"; if (typeof(TargetDates29614)=="undefined") TargetDates29614 = "04/26/2024 11:00:00 PM"; if (typeof(DisplayFormats29614)=="undefined") DisplayFormats29614 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives29614)=="undefined") CountActives29614 = true; if (typeof(FinishMessages29614)=="undefined") FinishMessages29614 = ""; if (typeof(CountSteppers29614)!="number") CountSteppers29614 = -1; if (typeof(LeadingZeros29614)=="undefined") LeadingZeros29614 = true; CountSteppers29614 = Math.ceil(CountSteppers29614); if (CountSteppers29614 == 0) CountActives29614 = false; var SetTimeOutPeriods29614 = (Math.abs(CountSteppers29614)-1)*1000 + 990; puti(BackColors29614, ForeColors29614); var dthens29614 = new Date(TargetDates29614); var dnows29614 = new Date("05/04/2024 2:09:00 AM"); if(CountSteppers29614>0) ddiffs29614 = new Date(dnows29614-dthens29614); else ddiffs29614 = new Date(dthens29614-dnows29614); gsecss29614 = Math.floor(ddiffs29614.valueOf()/1000); CountBacks29614(gsecss29614);