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 (LeadingZeros27739 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks27739(secs) { if (secs < 0) { document.getElementById("cntdwns27739").innerHTML = FinishMessages27739; return; } DisplayStrs27739 = DisplayFormats27739.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs27739 = DisplayStrs27739.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs27739 = DisplayStrs27739.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs27739 = DisplayStrs27739.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns27739").innerHTML = DisplayStrs27739; if (CountActives27739) //alert(SetTimeOutPeriods27739); setTimeout("CountBacks27739(" + (secs+CountSteppers27739) + ")", SetTimeOutPeriods27739); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors27739)=="undefined") BackColors27739 = ""; if (typeof(ForeColors27739)=="undefined") ForeColors27739= "white"; if (typeof(TargetDates27739)=="undefined") TargetDates27739 = "06/13/2023 11:00:00 PM"; if (typeof(DisplayFormats27739)=="undefined") DisplayFormats27739 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives27739)=="undefined") CountActives27739 = true; if (typeof(FinishMessages27739)=="undefined") FinishMessages27739 = ""; if (typeof(CountSteppers27739)!="number") CountSteppers27739 = -1; if (typeof(LeadingZeros27739)=="undefined") LeadingZeros27739 = true; CountSteppers27739 = Math.ceil(CountSteppers27739); if (CountSteppers27739 == 0) CountActives27739 = false; var SetTimeOutPeriods27739 = (Math.abs(CountSteppers27739)-1)*1000 + 990; puti(BackColors27739, ForeColors27739); var dthens27739 = new Date(TargetDates27739); var dnows27739 = new Date("05/11/2025 10:57:21 AM"); if(CountSteppers27739>0) ddiffs27739 = new Date(dnows27739-dthens27739); else ddiffs27739 = new Date(dthens27739-dnows27739); gsecss27739 = Math.floor(ddiffs27739.valueOf()/1000); CountBacks27739(gsecss27739);