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 (LeadingZeros28590 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks28590(secs) { if (secs < 0) { document.getElementById("cntdwns28590").innerHTML = FinishMessages28590; return; } DisplayStrs28590 = DisplayFormats28590.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs28590 = DisplayStrs28590.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs28590 = DisplayStrs28590.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs28590 = DisplayStrs28590.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns28590").innerHTML = DisplayStrs28590; if (CountActives28590) //alert(SetTimeOutPeriods28590); setTimeout("CountBacks28590(" + (secs+CountSteppers28590) + ")", SetTimeOutPeriods28590); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors28590)=="undefined") BackColors28590 = ""; if (typeof(ForeColors28590)=="undefined") ForeColors28590= "white"; if (typeof(TargetDates28590)=="undefined") TargetDates28590 = "06/07/2023 10:00:00 PM"; if (typeof(DisplayFormats28590)=="undefined") DisplayFormats28590 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives28590)=="undefined") CountActives28590 = true; if (typeof(FinishMessages28590)=="undefined") FinishMessages28590 = ""; if (typeof(CountSteppers28590)!="number") CountSteppers28590 = -1; if (typeof(LeadingZeros28590)=="undefined") LeadingZeros28590 = true; CountSteppers28590 = Math.ceil(CountSteppers28590); if (CountSteppers28590 == 0) CountActives28590 = false; var SetTimeOutPeriods28590 = (Math.abs(CountSteppers28590)-1)*1000 + 990; puti(BackColors28590, ForeColors28590); var dthens28590 = new Date(TargetDates28590); var dnows28590 = new Date("05/11/2025 5:42:37 PM"); if(CountSteppers28590>0) ddiffs28590 = new Date(dnows28590-dthens28590); else ddiffs28590 = new Date(dthens28590-dnows28590); gsecss28590 = Math.floor(ddiffs28590.valueOf()/1000); CountBacks28590(gsecss28590);