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 (LeadingZeros30286 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30286(secs) { if (secs < 0) { document.getElementById("cntdwns30286").innerHTML = FinishMessages30286; return; } DisplayStrs30286 = DisplayFormats30286.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30286 = DisplayStrs30286.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30286 = DisplayStrs30286.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30286 = DisplayStrs30286.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30286").innerHTML = DisplayStrs30286; if (CountActives30286) //alert(SetTimeOutPeriods30286); setTimeout("CountBacks30286(" + (secs+CountSteppers30286) + ")", SetTimeOutPeriods30286); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30286)=="undefined") BackColors30286 = ""; if (typeof(ForeColors30286)=="undefined") ForeColors30286= "white"; if (typeof(TargetDates30286)=="undefined") TargetDates30286 = "04/28/2024 10:00:00 PM"; if (typeof(DisplayFormats30286)=="undefined") DisplayFormats30286 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30286)=="undefined") CountActives30286 = true; if (typeof(FinishMessages30286)=="undefined") FinishMessages30286 = ""; if (typeof(CountSteppers30286)!="number") CountSteppers30286 = -1; if (typeof(LeadingZeros30286)=="undefined") LeadingZeros30286 = true; CountSteppers30286 = Math.ceil(CountSteppers30286); if (CountSteppers30286 == 0) CountActives30286 = false; var SetTimeOutPeriods30286 = (Math.abs(CountSteppers30286)-1)*1000 + 990; puti(BackColors30286, ForeColors30286); var dthens30286 = new Date(TargetDates30286); var dnows30286 = new Date("05/05/2024 11:45:14 AM"); if(CountSteppers30286>0) ddiffs30286 = new Date(dnows30286-dthens30286); else ddiffs30286 = new Date(dthens30286-dnows30286); gsecss30286 = Math.floor(ddiffs30286.valueOf()/1000); CountBacks30286(gsecss30286);