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 (LeadingZeros28399 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks28399(secs) { if (secs < 0) { document.getElementById("cntdwns28399").innerHTML = FinishMessages28399; return; } DisplayStrs28399 = DisplayFormats28399.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs28399 = DisplayStrs28399.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs28399 = DisplayStrs28399.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs28399 = DisplayStrs28399.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns28399").innerHTML = DisplayStrs28399; if (CountActives28399) //alert(SetTimeOutPeriods28399); setTimeout("CountBacks28399(" + (secs+CountSteppers28399) + ")", SetTimeOutPeriods28399); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors28399)=="undefined") BackColors28399 = ""; if (typeof(ForeColors28399)=="undefined") ForeColors28399= "white"; if (typeof(TargetDates28399)=="undefined") TargetDates28399 = "06/02/2023 10:00:00 PM"; if (typeof(DisplayFormats28399)=="undefined") DisplayFormats28399 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives28399)=="undefined") CountActives28399 = true; if (typeof(FinishMessages28399)=="undefined") FinishMessages28399 = ""; if (typeof(CountSteppers28399)!="number") CountSteppers28399 = -1; if (typeof(LeadingZeros28399)=="undefined") LeadingZeros28399 = true; CountSteppers28399 = Math.ceil(CountSteppers28399); if (CountSteppers28399 == 0) CountActives28399 = false; var SetTimeOutPeriods28399 = (Math.abs(CountSteppers28399)-1)*1000 + 990; puti(BackColors28399, ForeColors28399); var dthens28399 = new Date(TargetDates28399); var dnows28399 = new Date("05/09/2025 10:07:50 AM"); if(CountSteppers28399>0) ddiffs28399 = new Date(dnows28399-dthens28399); else ddiffs28399 = new Date(dthens28399-dnows28399); gsecss28399 = Math.floor(ddiffs28399.valueOf()/1000); CountBacks28399(gsecss28399);