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 (LeadingZeros29669 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks29669(secs) { if (secs < 0) { document.getElementById("cntdwns29669").innerHTML = FinishMessages29669; return; } DisplayStrs29669 = DisplayFormats29669.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs29669 = DisplayStrs29669.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs29669 = DisplayStrs29669.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs29669 = DisplayStrs29669.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns29669").innerHTML = DisplayStrs29669; if (CountActives29669) //alert(SetTimeOutPeriods29669); setTimeout("CountBacks29669(" + (secs+CountSteppers29669) + ")", SetTimeOutPeriods29669); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors29669)=="undefined") BackColors29669 = ""; if (typeof(ForeColors29669)=="undefined") ForeColors29669= "white"; if (typeof(TargetDates29669)=="undefined") TargetDates29669 = "04/01/2024 11:00:00 PM"; if (typeof(DisplayFormats29669)=="undefined") DisplayFormats29669 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives29669)=="undefined") CountActives29669 = true; if (typeof(FinishMessages29669)=="undefined") FinishMessages29669 = ""; if (typeof(CountSteppers29669)!="number") CountSteppers29669 = -1; if (typeof(LeadingZeros29669)=="undefined") LeadingZeros29669 = true; CountSteppers29669 = Math.ceil(CountSteppers29669); if (CountSteppers29669 == 0) CountActives29669 = false; var SetTimeOutPeriods29669 = (Math.abs(CountSteppers29669)-1)*1000 + 990; puti(BackColors29669, ForeColors29669); var dthens29669 = new Date(TargetDates29669); var dnows29669 = new Date("04/29/2024 3:14:09 PM"); if(CountSteppers29669>0) ddiffs29669 = new Date(dnows29669-dthens29669); else ddiffs29669 = new Date(dthens29669-dnows29669); gsecss29669 = Math.floor(ddiffs29669.valueOf()/1000); CountBacks29669(gsecss29669);