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 (LeadingZeros30184 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30184(secs) { if (secs < 0) { document.getElementById("cntdwns30184").innerHTML = FinishMessages30184; return; } DisplayStrs30184 = DisplayFormats30184.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30184 = DisplayStrs30184.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30184 = DisplayStrs30184.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30184 = DisplayStrs30184.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30184").innerHTML = DisplayStrs30184; if (CountActives30184) //alert(SetTimeOutPeriods30184); setTimeout("CountBacks30184(" + (secs+CountSteppers30184) + ")", SetTimeOutPeriods30184); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30184)=="undefined") BackColors30184 = ""; if (typeof(ForeColors30184)=="undefined") ForeColors30184= "white"; if (typeof(TargetDates30184)=="undefined") TargetDates30184 = "04/22/2024 10:00:00 PM"; if (typeof(DisplayFormats30184)=="undefined") DisplayFormats30184 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30184)=="undefined") CountActives30184 = true; if (typeof(FinishMessages30184)=="undefined") FinishMessages30184 = ""; if (typeof(CountSteppers30184)!="number") CountSteppers30184 = -1; if (typeof(LeadingZeros30184)=="undefined") LeadingZeros30184 = true; CountSteppers30184 = Math.ceil(CountSteppers30184); if (CountSteppers30184 == 0) CountActives30184 = false; var SetTimeOutPeriods30184 = (Math.abs(CountSteppers30184)-1)*1000 + 990; puti(BackColors30184, ForeColors30184); var dthens30184 = new Date(TargetDates30184); var dnows30184 = new Date("05/02/2024 5:49:31 AM"); if(CountSteppers30184>0) ddiffs30184 = new Date(dnows30184-dthens30184); else ddiffs30184 = new Date(dthens30184-dnows30184); gsecss30184 = Math.floor(ddiffs30184.valueOf()/1000); CountBacks30184(gsecss30184);