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 (LeadingZeros29755 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks29755(secs) { if (secs < 0) { document.getElementById("cntdwns29755").innerHTML = FinishMessages29755; return; } DisplayStrs29755 = DisplayFormats29755.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs29755 = DisplayStrs29755.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs29755 = DisplayStrs29755.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs29755 = DisplayStrs29755.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns29755").innerHTML = DisplayStrs29755; if (CountActives29755) //alert(SetTimeOutPeriods29755); setTimeout("CountBacks29755(" + (secs+CountSteppers29755) + ")", SetTimeOutPeriods29755); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors29755)=="undefined") BackColors29755 = ""; if (typeof(ForeColors29755)=="undefined") ForeColors29755= "white"; if (typeof(TargetDates29755)=="undefined") TargetDates29755 = "04/29/2024 11:00:00 PM"; if (typeof(DisplayFormats29755)=="undefined") DisplayFormats29755 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives29755)=="undefined") CountActives29755 = true; if (typeof(FinishMessages29755)=="undefined") FinishMessages29755 = ""; if (typeof(CountSteppers29755)!="number") CountSteppers29755 = -1; if (typeof(LeadingZeros29755)=="undefined") LeadingZeros29755 = true; CountSteppers29755 = Math.ceil(CountSteppers29755); if (CountSteppers29755 == 0) CountActives29755 = false; var SetTimeOutPeriods29755 = (Math.abs(CountSteppers29755)-1)*1000 + 990; puti(BackColors29755, ForeColors29755); var dthens29755 = new Date(TargetDates29755); var dnows29755 = new Date("05/09/2024 1:27:44 AM"); if(CountSteppers29755>0) ddiffs29755 = new Date(dnows29755-dthens29755); else ddiffs29755 = new Date(dthens29755-dnows29755); gsecss29755 = Math.floor(ddiffs29755.valueOf()/1000); CountBacks29755(gsecss29755);