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 (LeadingZeros29991 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks29991(secs) { if (secs < 0) { document.getElementById("cntdwns29991").innerHTML = FinishMessages29991; return; } DisplayStrs29991 = DisplayFormats29991.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs29991 = DisplayStrs29991.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs29991 = DisplayStrs29991.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs29991 = DisplayStrs29991.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns29991").innerHTML = DisplayStrs29991; if (CountActives29991) //alert(SetTimeOutPeriods29991); setTimeout("CountBacks29991(" + (secs+CountSteppers29991) + ")", SetTimeOutPeriods29991); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors29991)=="undefined") BackColors29991 = ""; if (typeof(ForeColors29991)=="undefined") ForeColors29991= "white"; if (typeof(TargetDates29991)=="undefined") TargetDates29991 = "04/19/2024 10:00:00 PM"; if (typeof(DisplayFormats29991)=="undefined") DisplayFormats29991 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives29991)=="undefined") CountActives29991 = true; if (typeof(FinishMessages29991)=="undefined") FinishMessages29991 = ""; if (typeof(CountSteppers29991)!="number") CountSteppers29991 = -1; if (typeof(LeadingZeros29991)=="undefined") LeadingZeros29991 = true; CountSteppers29991 = Math.ceil(CountSteppers29991); if (CountSteppers29991 == 0) CountActives29991 = false; var SetTimeOutPeriods29991 = (Math.abs(CountSteppers29991)-1)*1000 + 990; puti(BackColors29991, ForeColors29991); var dthens29991 = new Date(TargetDates29991); var dnows29991 = new Date("04/29/2024 9:26:44 PM"); if(CountSteppers29991>0) ddiffs29991 = new Date(dnows29991-dthens29991); else ddiffs29991 = new Date(dthens29991-dnows29991); gsecss29991 = Math.floor(ddiffs29991.valueOf()/1000); CountBacks29991(gsecss29991);