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 (LeadingZeros28510 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks28510(secs) { if (secs < 0) { document.getElementById("cntdwns28510").innerHTML = FinishMessages28510; return; } DisplayStrs28510 = DisplayFormats28510.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs28510 = DisplayStrs28510.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs28510 = DisplayStrs28510.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs28510 = DisplayStrs28510.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns28510").innerHTML = DisplayStrs28510; if (CountActives28510) //alert(SetTimeOutPeriods28510); setTimeout("CountBacks28510(" + (secs+CountSteppers28510) + ")", SetTimeOutPeriods28510); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors28510)=="undefined") BackColors28510 = ""; if (typeof(ForeColors28510)=="undefined") ForeColors28510= "white"; if (typeof(TargetDates28510)=="undefined") TargetDates28510 = "06/05/2023 10:00:00 PM"; if (typeof(DisplayFormats28510)=="undefined") DisplayFormats28510 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives28510)=="undefined") CountActives28510 = true; if (typeof(FinishMessages28510)=="undefined") FinishMessages28510 = ""; if (typeof(CountSteppers28510)!="number") CountSteppers28510 = -1; if (typeof(LeadingZeros28510)=="undefined") LeadingZeros28510 = true; CountSteppers28510 = Math.ceil(CountSteppers28510); if (CountSteppers28510 == 0) CountActives28510 = false; var SetTimeOutPeriods28510 = (Math.abs(CountSteppers28510)-1)*1000 + 990; puti(BackColors28510, ForeColors28510); var dthens28510 = new Date(TargetDates28510); var dnows28510 = new Date("05/11/2025 1:35:06 AM"); if(CountSteppers28510>0) ddiffs28510 = new Date(dnows28510-dthens28510); else ddiffs28510 = new Date(dthens28510-dnows28510); gsecss28510 = Math.floor(ddiffs28510.valueOf()/1000); CountBacks28510(gsecss28510);