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 (LeadingZeros28350 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks28350(secs) { if (secs < 0) { document.getElementById("cntdwns28350").innerHTML = FinishMessages28350; return; } DisplayStrs28350 = DisplayFormats28350.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs28350 = DisplayStrs28350.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs28350 = DisplayStrs28350.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs28350 = DisplayStrs28350.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns28350").innerHTML = DisplayStrs28350; if (CountActives28350) //alert(SetTimeOutPeriods28350); setTimeout("CountBacks28350(" + (secs+CountSteppers28350) + ")", SetTimeOutPeriods28350); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors28350)=="undefined") BackColors28350 = ""; if (typeof(ForeColors28350)=="undefined") ForeColors28350= "white"; if (typeof(TargetDates28350)=="undefined") TargetDates28350 = "05/30/2023 10:00:00 PM"; if (typeof(DisplayFormats28350)=="undefined") DisplayFormats28350 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives28350)=="undefined") CountActives28350 = true; if (typeof(FinishMessages28350)=="undefined") FinishMessages28350 = ""; if (typeof(CountSteppers28350)!="number") CountSteppers28350 = -1; if (typeof(LeadingZeros28350)=="undefined") LeadingZeros28350 = true; CountSteppers28350 = Math.ceil(CountSteppers28350); if (CountSteppers28350 == 0) CountActives28350 = false; var SetTimeOutPeriods28350 = (Math.abs(CountSteppers28350)-1)*1000 + 990; puti(BackColors28350, ForeColors28350); var dthens28350 = new Date(TargetDates28350); var dnows28350 = new Date("05/09/2025 10:07:50 AM"); if(CountSteppers28350>0) ddiffs28350 = new Date(dnows28350-dthens28350); else ddiffs28350 = new Date(dthens28350-dnows28350); gsecss28350 = Math.floor(ddiffs28350.valueOf()/1000); CountBacks28350(gsecss28350);