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 (LeadingZeros30733 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30733(secs) { if (secs < 0) { document.getElementById("cntdwns30733").innerHTML = FinishMessages30733; return; } DisplayStrs30733 = DisplayFormats30733.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30733 = DisplayStrs30733.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30733 = DisplayStrs30733.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30733 = DisplayStrs30733.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30733").innerHTML = DisplayStrs30733; if (CountActives30733) //alert(SetTimeOutPeriods30733); setTimeout("CountBacks30733(" + (secs+CountSteppers30733) + ")", SetTimeOutPeriods30733); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30733)=="undefined") BackColors30733 = ""; if (typeof(ForeColors30733)=="undefined") ForeColors30733= "white"; if (typeof(TargetDates30733)=="undefined") TargetDates30733 = "07/29/2024 10:00:00 PM"; if (typeof(DisplayFormats30733)=="undefined") DisplayFormats30733 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30733)=="undefined") CountActives30733 = true; if (typeof(FinishMessages30733)=="undefined") FinishMessages30733 = ""; if (typeof(CountSteppers30733)!="number") CountSteppers30733 = -1; if (typeof(LeadingZeros30733)=="undefined") LeadingZeros30733 = true; CountSteppers30733 = Math.ceil(CountSteppers30733); if (CountSteppers30733 == 0) CountActives30733 = false; var SetTimeOutPeriods30733 = (Math.abs(CountSteppers30733)-1)*1000 + 990; puti(BackColors30733, ForeColors30733); var dthens30733 = new Date(TargetDates30733); var dnows30733 = new Date("09/08/2024 2:05:15 AM"); if(CountSteppers30733>0) ddiffs30733 = new Date(dnows30733-dthens30733); else ddiffs30733 = new Date(dthens30733-dnows30733); gsecss30733 = Math.floor(ddiffs30733.valueOf()/1000); CountBacks30733(gsecss30733);