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 (LeadingZeros29150 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks29150(secs) { if (secs < 0) { document.getElementById("cntdwns29150").innerHTML = FinishMessages29150; return; } DisplayStrs29150 = DisplayFormats29150.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs29150 = DisplayStrs29150.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs29150 = DisplayStrs29150.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs29150 = DisplayStrs29150.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns29150").innerHTML = DisplayStrs29150; if (CountActives29150) //alert(SetTimeOutPeriods29150); setTimeout("CountBacks29150(" + (secs+CountSteppers29150) + ")", SetTimeOutPeriods29150); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors29150)=="undefined") BackColors29150 = ""; if (typeof(ForeColors29150)=="undefined") ForeColors29150= "white"; if (typeof(TargetDates29150)=="undefined") TargetDates29150 = "09/28/2023 10:00:00 PM"; if (typeof(DisplayFormats29150)=="undefined") DisplayFormats29150 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives29150)=="undefined") CountActives29150 = true; if (typeof(FinishMessages29150)=="undefined") FinishMessages29150 = ""; if (typeof(CountSteppers29150)!="number") CountSteppers29150 = -1; if (typeof(LeadingZeros29150)=="undefined") LeadingZeros29150 = true; CountSteppers29150 = Math.ceil(CountSteppers29150); if (CountSteppers29150 == 0) CountActives29150 = false; var SetTimeOutPeriods29150 = (Math.abs(CountSteppers29150)-1)*1000 + 990; puti(BackColors29150, ForeColors29150); var dthens29150 = new Date(TargetDates29150); var dnows29150 = new Date("05/11/2025 9:01:59 PM"); if(CountSteppers29150>0) ddiffs29150 = new Date(dnows29150-dthens29150); else ddiffs29150 = new Date(dthens29150-dnows29150); gsecss29150 = Math.floor(ddiffs29150.valueOf()/1000); CountBacks29150(gsecss29150);