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 (LeadingZeros30769 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30769(secs) { if (secs < 0) { document.getElementById("cntdwns30769").innerHTML = FinishMessages30769; return; } DisplayStrs30769 = DisplayFormats30769.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30769 = DisplayStrs30769.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30769 = DisplayStrs30769.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30769 = DisplayStrs30769.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30769").innerHTML = DisplayStrs30769; if (CountActives30769) //alert(SetTimeOutPeriods30769); setTimeout("CountBacks30769(" + (secs+CountSteppers30769) + ")", SetTimeOutPeriods30769); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30769)=="undefined") BackColors30769 = ""; if (typeof(ForeColors30769)=="undefined") ForeColors30769= "white"; if (typeof(TargetDates30769)=="undefined") TargetDates30769 = "07/29/2024 10:00:00 PM"; if (typeof(DisplayFormats30769)=="undefined") DisplayFormats30769 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30769)=="undefined") CountActives30769 = true; if (typeof(FinishMessages30769)=="undefined") FinishMessages30769 = ""; if (typeof(CountSteppers30769)!="number") CountSteppers30769 = -1; if (typeof(LeadingZeros30769)=="undefined") LeadingZeros30769 = true; CountSteppers30769 = Math.ceil(CountSteppers30769); if (CountSteppers30769 == 0) CountActives30769 = false; var SetTimeOutPeriods30769 = (Math.abs(CountSteppers30769)-1)*1000 + 990; puti(BackColors30769, ForeColors30769); var dthens30769 = new Date(TargetDates30769); var dnows30769 = new Date("10/18/2024 6:18:39 AM"); if(CountSteppers30769>0) ddiffs30769 = new Date(dnows30769-dthens30769); else ddiffs30769 = new Date(dthens30769-dnows30769); gsecss30769 = Math.floor(ddiffs30769.valueOf()/1000); CountBacks30769(gsecss30769);