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 (LeadingZeros30084 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30084(secs) { if (secs < 0) { document.getElementById("cntdwns30084").innerHTML = FinishMessages30084; return; } DisplayStrs30084 = DisplayFormats30084.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30084 = DisplayStrs30084.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30084 = DisplayStrs30084.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30084 = DisplayStrs30084.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30084").innerHTML = DisplayStrs30084; if (CountActives30084) //alert(SetTimeOutPeriods30084); setTimeout("CountBacks30084(" + (secs+CountSteppers30084) + ")", SetTimeOutPeriods30084); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30084)=="undefined") BackColors30084 = ""; if (typeof(ForeColors30084)=="undefined") ForeColors30084= "white"; if (typeof(TargetDates30084)=="undefined") TargetDates30084 = "04/21/2024 11:00:00 PM"; if (typeof(DisplayFormats30084)=="undefined") DisplayFormats30084 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30084)=="undefined") CountActives30084 = true; if (typeof(FinishMessages30084)=="undefined") FinishMessages30084 = ""; if (typeof(CountSteppers30084)!="number") CountSteppers30084 = -1; if (typeof(LeadingZeros30084)=="undefined") LeadingZeros30084 = true; CountSteppers30084 = Math.ceil(CountSteppers30084); if (CountSteppers30084 == 0) CountActives30084 = false; var SetTimeOutPeriods30084 = (Math.abs(CountSteppers30084)-1)*1000 + 990; puti(BackColors30084, ForeColors30084); var dthens30084 = new Date(TargetDates30084); var dnows30084 = new Date("05/02/2024 1:56:03 PM"); if(CountSteppers30084>0) ddiffs30084 = new Date(dnows30084-dthens30084); else ddiffs30084 = new Date(dthens30084-dnows30084); gsecss30084 = Math.floor(ddiffs30084.valueOf()/1000); CountBacks30084(gsecss30084);