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 (LeadingZeros30163 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30163(secs) { if (secs < 0) { document.getElementById("cntdwns30163").innerHTML = FinishMessages30163; return; } DisplayStrs30163 = DisplayFormats30163.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30163 = DisplayStrs30163.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30163 = DisplayStrs30163.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30163 = DisplayStrs30163.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30163").innerHTML = DisplayStrs30163; if (CountActives30163) //alert(SetTimeOutPeriods30163); setTimeout("CountBacks30163(" + (secs+CountSteppers30163) + ")", SetTimeOutPeriods30163); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30163)=="undefined") BackColors30163 = ""; if (typeof(ForeColors30163)=="undefined") ForeColors30163= "white"; if (typeof(TargetDates30163)=="undefined") TargetDates30163 = "03/30/2024 9:00:00 PM"; if (typeof(DisplayFormats30163)=="undefined") DisplayFormats30163 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30163)=="undefined") CountActives30163 = true; if (typeof(FinishMessages30163)=="undefined") FinishMessages30163 = ""; if (typeof(CountSteppers30163)!="number") CountSteppers30163 = -1; if (typeof(LeadingZeros30163)=="undefined") LeadingZeros30163 = true; CountSteppers30163 = Math.ceil(CountSteppers30163); if (CountSteppers30163 == 0) CountActives30163 = false; var SetTimeOutPeriods30163 = (Math.abs(CountSteppers30163)-1)*1000 + 990; puti(BackColors30163, ForeColors30163); var dthens30163 = new Date(TargetDates30163); var dnows30163 = new Date("04/28/2024 5:30:17 PM"); if(CountSteppers30163>0) ddiffs30163 = new Date(dnows30163-dthens30163); else ddiffs30163 = new Date(dthens30163-dnows30163); gsecss30163 = Math.floor(ddiffs30163.valueOf()/1000); CountBacks30163(gsecss30163);