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 (LeadingZeros30137 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30137(secs) { if (secs < 0) { document.getElementById("cntdwns30137").innerHTML = FinishMessages30137; return; } DisplayStrs30137 = DisplayFormats30137.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30137 = DisplayStrs30137.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30137 = DisplayStrs30137.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30137 = DisplayStrs30137.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30137").innerHTML = DisplayStrs30137; if (CountActives30137) //alert(SetTimeOutPeriods30137); setTimeout("CountBacks30137(" + (secs+CountSteppers30137) + ")", SetTimeOutPeriods30137); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30137)=="undefined") BackColors30137 = ""; if (typeof(ForeColors30137)=="undefined") ForeColors30137= "white"; if (typeof(TargetDates30137)=="undefined") TargetDates30137 = "03/31/2024 11:00:00 PM"; if (typeof(DisplayFormats30137)=="undefined") DisplayFormats30137 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30137)=="undefined") CountActives30137 = true; if (typeof(FinishMessages30137)=="undefined") FinishMessages30137 = ""; if (typeof(CountSteppers30137)!="number") CountSteppers30137 = -1; if (typeof(LeadingZeros30137)=="undefined") LeadingZeros30137 = true; CountSteppers30137 = Math.ceil(CountSteppers30137); if (CountSteppers30137 == 0) CountActives30137 = false; var SetTimeOutPeriods30137 = (Math.abs(CountSteppers30137)-1)*1000 + 990; puti(BackColors30137, ForeColors30137); var dthens30137 = new Date(TargetDates30137); var dnows30137 = new Date("04/29/2024 10:26:56 AM"); if(CountSteppers30137>0) ddiffs30137 = new Date(dnows30137-dthens30137); else ddiffs30137 = new Date(dthens30137-dnows30137); gsecss30137 = Math.floor(ddiffs30137.valueOf()/1000); CountBacks30137(gsecss30137);