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 (LeadingZeros28385 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks28385(secs) { if (secs < 0) { document.getElementById("cntdwns28385").innerHTML = FinishMessages28385; return; } DisplayStrs28385 = DisplayFormats28385.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs28385 = DisplayStrs28385.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs28385 = DisplayStrs28385.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs28385 = DisplayStrs28385.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns28385").innerHTML = DisplayStrs28385; if (CountActives28385) //alert(SetTimeOutPeriods28385); setTimeout("CountBacks28385(" + (secs+CountSteppers28385) + ")", SetTimeOutPeriods28385); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors28385)=="undefined") BackColors28385 = ""; if (typeof(ForeColors28385)=="undefined") ForeColors28385= "white"; if (typeof(TargetDates28385)=="undefined") TargetDates28385 = "06/06/2023 10:00:00 PM"; if (typeof(DisplayFormats28385)=="undefined") DisplayFormats28385 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives28385)=="undefined") CountActives28385 = true; if (typeof(FinishMessages28385)=="undefined") FinishMessages28385 = ""; if (typeof(CountSteppers28385)!="number") CountSteppers28385 = -1; if (typeof(LeadingZeros28385)=="undefined") LeadingZeros28385 = true; CountSteppers28385 = Math.ceil(CountSteppers28385); if (CountSteppers28385 == 0) CountActives28385 = false; var SetTimeOutPeriods28385 = (Math.abs(CountSteppers28385)-1)*1000 + 990; puti(BackColors28385, ForeColors28385); var dthens28385 = new Date(TargetDates28385); var dnows28385 = new Date("05/09/2025 10:10:28 AM"); if(CountSteppers28385>0) ddiffs28385 = new Date(dnows28385-dthens28385); else ddiffs28385 = new Date(dthens28385-dnows28385); gsecss28385 = Math.floor(ddiffs28385.valueOf()/1000); CountBacks28385(gsecss28385);