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 (LeadingZeros30019 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30019(secs) { if (secs < 0) { document.getElementById("cntdwns30019").innerHTML = FinishMessages30019; return; } DisplayStrs30019 = DisplayFormats30019.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30019 = DisplayStrs30019.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30019 = DisplayStrs30019.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30019 = DisplayStrs30019.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30019").innerHTML = DisplayStrs30019; if (CountActives30019) //alert(SetTimeOutPeriods30019); setTimeout("CountBacks30019(" + (secs+CountSteppers30019) + ")", SetTimeOutPeriods30019); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30019)=="undefined") BackColors30019 = ""; if (typeof(ForeColors30019)=="undefined") ForeColors30019= "white"; if (typeof(TargetDates30019)=="undefined") TargetDates30019 = "04/21/2024 10:00:00 PM"; if (typeof(DisplayFormats30019)=="undefined") DisplayFormats30019 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30019)=="undefined") CountActives30019 = true; if (typeof(FinishMessages30019)=="undefined") FinishMessages30019 = ""; if (typeof(CountSteppers30019)!="number") CountSteppers30019 = -1; if (typeof(LeadingZeros30019)=="undefined") LeadingZeros30019 = true; CountSteppers30019 = Math.ceil(CountSteppers30019); if (CountSteppers30019 == 0) CountActives30019 = false; var SetTimeOutPeriods30019 = (Math.abs(CountSteppers30019)-1)*1000 + 990; puti(BackColors30019, ForeColors30019); var dthens30019 = new Date(TargetDates30019); var dnows30019 = new Date("05/02/2024 1:05:22 AM"); if(CountSteppers30019>0) ddiffs30019 = new Date(dnows30019-dthens30019); else ddiffs30019 = new Date(dthens30019-dnows30019); gsecss30019 = Math.floor(ddiffs30019.valueOf()/1000); CountBacks30019(gsecss30019);