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 (LeadingZeros29378 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks29378(secs) { if (secs < 0) { document.getElementById("cntdwns29378").innerHTML = FinishMessages29378; return; } DisplayStrs29378 = DisplayFormats29378.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs29378 = DisplayStrs29378.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs29378 = DisplayStrs29378.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs29378 = DisplayStrs29378.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns29378").innerHTML = DisplayStrs29378; if (CountActives29378) //alert(SetTimeOutPeriods29378); setTimeout("CountBacks29378(" + (secs+CountSteppers29378) + ")", SetTimeOutPeriods29378); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors29378)=="undefined") BackColors29378 = ""; if (typeof(ForeColors29378)=="undefined") ForeColors29378= "white"; if (typeof(TargetDates29378)=="undefined") TargetDates29378 = "12/11/2023 9:00:00 PM"; if (typeof(DisplayFormats29378)=="undefined") DisplayFormats29378 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives29378)=="undefined") CountActives29378 = true; if (typeof(FinishMessages29378)=="undefined") FinishMessages29378 = ""; if (typeof(CountSteppers29378)!="number") CountSteppers29378 = -1; if (typeof(LeadingZeros29378)=="undefined") LeadingZeros29378 = true; CountSteppers29378 = Math.ceil(CountSteppers29378); if (CountSteppers29378 == 0) CountActives29378 = false; var SetTimeOutPeriods29378 = (Math.abs(CountSteppers29378)-1)*1000 + 990; puti(BackColors29378, ForeColors29378); var dthens29378 = new Date(TargetDates29378); var dnows29378 = new Date("05/11/2025 9:04:34 PM"); if(CountSteppers29378>0) ddiffs29378 = new Date(dnows29378-dthens29378); else ddiffs29378 = new Date(dthens29378-dnows29378); gsecss29378 = Math.floor(ddiffs29378.valueOf()/1000); CountBacks29378(gsecss29378);