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 (LeadingZeros31862 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks31862(secs) { if (secs < 0) { document.getElementById("cntdwns31862").innerHTML = FinishMessages31862; return; } DisplayStrs31862 = DisplayFormats31862.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs31862 = DisplayStrs31862.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs31862 = DisplayStrs31862.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs31862 = DisplayStrs31862.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns31862").innerHTML = DisplayStrs31862; if (CountActives31862) //alert(SetTimeOutPeriods31862); setTimeout("CountBacks31862(" + (secs+CountSteppers31862) + ")", SetTimeOutPeriods31862); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors31862)=="undefined") BackColors31862 = ""; if (typeof(ForeColors31862)=="undefined") ForeColors31862= "white"; if (typeof(TargetDates31862)=="undefined") TargetDates31862 = "02/24/2025 10:00:00 PM"; if (typeof(DisplayFormats31862)=="undefined") DisplayFormats31862 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives31862)=="undefined") CountActives31862 = true; if (typeof(FinishMessages31862)=="undefined") FinishMessages31862 = ""; if (typeof(CountSteppers31862)!="number") CountSteppers31862 = -1; if (typeof(LeadingZeros31862)=="undefined") LeadingZeros31862 = true; CountSteppers31862 = Math.ceil(CountSteppers31862); if (CountSteppers31862 == 0) CountActives31862 = false; var SetTimeOutPeriods31862 = (Math.abs(CountSteppers31862)-1)*1000 + 990; puti(BackColors31862, ForeColors31862); var dthens31862 = new Date(TargetDates31862); var dnows31862 = new Date("02/22/2025 9:59:51 PM"); if(CountSteppers31862>0) ddiffs31862 = new Date(dnows31862-dthens31862); else ddiffs31862 = new Date(dthens31862-dnows31862); gsecss31862 = Math.floor(ddiffs31862.valueOf()/1000); CountBacks31862(gsecss31862);