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 (LeadingZeros28031 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks28031(secs) { if (secs < 0) { document.getElementById("cntdwns28031").innerHTML = FinishMessages28031; return; } DisplayStrs28031 = DisplayFormats28031.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs28031 = DisplayStrs28031.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs28031 = DisplayStrs28031.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs28031 = DisplayStrs28031.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns28031").innerHTML = DisplayStrs28031; if (CountActives28031) //alert(SetTimeOutPeriods28031); setTimeout("CountBacks28031(" + (secs+CountSteppers28031) + ")", SetTimeOutPeriods28031); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors28031)=="undefined") BackColors28031 = ""; if (typeof(ForeColors28031)=="undefined") ForeColors28031= "white"; if (typeof(TargetDates28031)=="undefined") TargetDates28031 = "03/29/2023 11:00:00 PM"; if (typeof(DisplayFormats28031)=="undefined") DisplayFormats28031 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives28031)=="undefined") CountActives28031 = true; if (typeof(FinishMessages28031)=="undefined") FinishMessages28031 = ""; if (typeof(CountSteppers28031)!="number") CountSteppers28031 = -1; if (typeof(LeadingZeros28031)=="undefined") LeadingZeros28031 = true; CountSteppers28031 = Math.ceil(CountSteppers28031); if (CountSteppers28031 == 0) CountActives28031 = false; var SetTimeOutPeriods28031 = (Math.abs(CountSteppers28031)-1)*1000 + 990; puti(BackColors28031, ForeColors28031); var dthens28031 = new Date(TargetDates28031); var dnows28031 = new Date("05/13/2025 3:41:40 PM"); if(CountSteppers28031>0) ddiffs28031 = new Date(dnows28031-dthens28031); else ddiffs28031 = new Date(dthens28031-dnows28031); gsecss28031 = Math.floor(ddiffs28031.valueOf()/1000); CountBacks28031(gsecss28031);