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 (LeadingZeros29471 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks29471(secs) { if (secs < 0) { document.getElementById("cntdwns29471").innerHTML = FinishMessages29471; return; } DisplayStrs29471 = DisplayFormats29471.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs29471 = DisplayStrs29471.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs29471 = DisplayStrs29471.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs29471 = DisplayStrs29471.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns29471").innerHTML = DisplayStrs29471; if (CountActives29471) //alert(SetTimeOutPeriods29471); setTimeout("CountBacks29471(" + (secs+CountSteppers29471) + ")", SetTimeOutPeriods29471); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors29471)=="undefined") BackColors29471 = ""; if (typeof(ForeColors29471)=="undefined") ForeColors29471= "white"; if (typeof(TargetDates29471)=="undefined") TargetDates29471 = "04/29/2024 11:00:00 PM"; if (typeof(DisplayFormats29471)=="undefined") DisplayFormats29471 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives29471)=="undefined") CountActives29471 = true; if (typeof(FinishMessages29471)=="undefined") FinishMessages29471 = ""; if (typeof(CountSteppers29471)!="number") CountSteppers29471 = -1; if (typeof(LeadingZeros29471)=="undefined") LeadingZeros29471 = true; CountSteppers29471 = Math.ceil(CountSteppers29471); if (CountSteppers29471 == 0) CountActives29471 = false; var SetTimeOutPeriods29471 = (Math.abs(CountSteppers29471)-1)*1000 + 990; puti(BackColors29471, ForeColors29471); var dthens29471 = new Date(TargetDates29471); var dnows29471 = new Date("05/07/2024 6:14:29 AM"); if(CountSteppers29471>0) ddiffs29471 = new Date(dnows29471-dthens29471); else ddiffs29471 = new Date(dthens29471-dnows29471); gsecss29471 = Math.floor(ddiffs29471.valueOf()/1000); CountBacks29471(gsecss29471);