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 (LeadingZeros27501 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks27501(secs) { if (secs < 0) { document.getElementById("cntdwns27501").innerHTML = FinishMessages27501; return; } DisplayStrs27501 = DisplayFormats27501.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs27501 = DisplayStrs27501.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs27501 = DisplayStrs27501.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs27501 = DisplayStrs27501.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns27501").innerHTML = DisplayStrs27501; if (CountActives27501) //alert(SetTimeOutPeriods27501); setTimeout("CountBacks27501(" + (secs+CountSteppers27501) + ")", SetTimeOutPeriods27501); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors27501)=="undefined") BackColors27501 = ""; if (typeof(ForeColors27501)=="undefined") ForeColors27501= "white"; if (typeof(TargetDates27501)=="undefined") TargetDates27501 = "04/01/2023 11:00:00 PM"; if (typeof(DisplayFormats27501)=="undefined") DisplayFormats27501 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives27501)=="undefined") CountActives27501 = true; if (typeof(FinishMessages27501)=="undefined") FinishMessages27501 = ""; if (typeof(CountSteppers27501)!="number") CountSteppers27501 = -1; if (typeof(LeadingZeros27501)=="undefined") LeadingZeros27501 = true; CountSteppers27501 = Math.ceil(CountSteppers27501); if (CountSteppers27501 == 0) CountActives27501 = false; var SetTimeOutPeriods27501 = (Math.abs(CountSteppers27501)-1)*1000 + 990; puti(BackColors27501, ForeColors27501); var dthens27501 = new Date(TargetDates27501); var dnows27501 = new Date("05/13/2025 4:20:38 AM"); if(CountSteppers27501>0) ddiffs27501 = new Date(dnows27501-dthens27501); else ddiffs27501 = new Date(dthens27501-dnows27501); gsecss27501 = Math.floor(ddiffs27501.valueOf()/1000); CountBacks27501(gsecss27501);