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 (LeadingZeros30835 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30835(secs) { if (secs < 0) { document.getElementById("cntdwns30835").innerHTML = FinishMessages30835; return; } DisplayStrs30835 = DisplayFormats30835.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30835 = DisplayStrs30835.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30835 = DisplayStrs30835.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30835 = DisplayStrs30835.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30835").innerHTML = DisplayStrs30835; if (CountActives30835) //alert(SetTimeOutPeriods30835); setTimeout("CountBacks30835(" + (secs+CountSteppers30835) + ")", SetTimeOutPeriods30835); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30835)=="undefined") BackColors30835 = ""; if (typeof(ForeColors30835)=="undefined") ForeColors30835= "white"; if (typeof(TargetDates30835)=="undefined") TargetDates30835 = "07/30/2024 10:00:00 PM"; if (typeof(DisplayFormats30835)=="undefined") DisplayFormats30835 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30835)=="undefined") CountActives30835 = true; if (typeof(FinishMessages30835)=="undefined") FinishMessages30835 = ""; if (typeof(CountSteppers30835)!="number") CountSteppers30835 = -1; if (typeof(LeadingZeros30835)=="undefined") LeadingZeros30835 = true; CountSteppers30835 = Math.ceil(CountSteppers30835); if (CountSteppers30835 == 0) CountActives30835 = false; var SetTimeOutPeriods30835 = (Math.abs(CountSteppers30835)-1)*1000 + 990; puti(BackColors30835, ForeColors30835); var dthens30835 = new Date(TargetDates30835); var dnows30835 = new Date("09/08/2024 2:29:29 AM"); if(CountSteppers30835>0) ddiffs30835 = new Date(dnows30835-dthens30835); else ddiffs30835 = new Date(dthens30835-dnows30835); gsecss30835 = Math.floor(ddiffs30835.valueOf()/1000); CountBacks30835(gsecss30835);