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 (LeadingZeros28242 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks28242(secs) { if (secs < 0) { document.getElementById("cntdwns28242").innerHTML = FinishMessages28242; return; } DisplayStrs28242 = DisplayFormats28242.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs28242 = DisplayStrs28242.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs28242 = DisplayStrs28242.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs28242 = DisplayStrs28242.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns28242").innerHTML = DisplayStrs28242; if (CountActives28242) //alert(SetTimeOutPeriods28242); setTimeout("CountBacks28242(" + (secs+CountSteppers28242) + ")", SetTimeOutPeriods28242); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors28242)=="undefined") BackColors28242 = ""; if (typeof(ForeColors28242)=="undefined") ForeColors28242= "white"; if (typeof(TargetDates28242)=="undefined") TargetDates28242 = "06/05/2023 10:00:00 PM"; if (typeof(DisplayFormats28242)=="undefined") DisplayFormats28242 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives28242)=="undefined") CountActives28242 = true; if (typeof(FinishMessages28242)=="undefined") FinishMessages28242 = ""; if (typeof(CountSteppers28242)!="number") CountSteppers28242 = -1; if (typeof(LeadingZeros28242)=="undefined") LeadingZeros28242 = true; CountSteppers28242 = Math.ceil(CountSteppers28242); if (CountSteppers28242 == 0) CountActives28242 = false; var SetTimeOutPeriods28242 = (Math.abs(CountSteppers28242)-1)*1000 + 990; puti(BackColors28242, ForeColors28242); var dthens28242 = new Date(TargetDates28242); var dnows28242 = new Date("05/09/2025 10:07:50 AM"); if(CountSteppers28242>0) ddiffs28242 = new Date(dnows28242-dthens28242); else ddiffs28242 = new Date(dthens28242-dnows28242); gsecss28242 = Math.floor(ddiffs28242.valueOf()/1000); CountBacks28242(gsecss28242);