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 (LeadingZeros30126 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30126(secs) { if (secs < 0) { document.getElementById("cntdwns30126").innerHTML = FinishMessages30126; return; } DisplayStrs30126 = DisplayFormats30126.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30126 = DisplayStrs30126.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30126 = DisplayStrs30126.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30126 = DisplayStrs30126.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30126").innerHTML = DisplayStrs30126; if (CountActives30126) //alert(SetTimeOutPeriods30126); setTimeout("CountBacks30126(" + (secs+CountSteppers30126) + ")", SetTimeOutPeriods30126); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30126)=="undefined") BackColors30126 = ""; if (typeof(ForeColors30126)=="undefined") ForeColors30126= "white"; if (typeof(TargetDates30126)=="undefined") TargetDates30126 = "04/01/2024 11:00:00 PM"; if (typeof(DisplayFormats30126)=="undefined") DisplayFormats30126 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30126)=="undefined") CountActives30126 = true; if (typeof(FinishMessages30126)=="undefined") FinishMessages30126 = ""; if (typeof(CountSteppers30126)!="number") CountSteppers30126 = -1; if (typeof(LeadingZeros30126)=="undefined") LeadingZeros30126 = true; CountSteppers30126 = Math.ceil(CountSteppers30126); if (CountSteppers30126 == 0) CountActives30126 = false; var SetTimeOutPeriods30126 = (Math.abs(CountSteppers30126)-1)*1000 + 990; puti(BackColors30126, ForeColors30126); var dthens30126 = new Date(TargetDates30126); var dnows30126 = new Date("04/28/2024 9:05:18 PM"); if(CountSteppers30126>0) ddiffs30126 = new Date(dnows30126-dthens30126); else ddiffs30126 = new Date(dthens30126-dnows30126); gsecss30126 = Math.floor(ddiffs30126.valueOf()/1000); CountBacks30126(gsecss30126);