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 (LeadingZeros29041 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks29041(secs) { if (secs < 0) { document.getElementById("cntdwns29041").innerHTML = FinishMessages29041; return; } DisplayStrs29041 = DisplayFormats29041.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs29041 = DisplayStrs29041.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs29041 = DisplayStrs29041.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs29041 = DisplayStrs29041.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns29041").innerHTML = DisplayStrs29041; if (CountActives29041) //alert(SetTimeOutPeriods29041); setTimeout("CountBacks29041(" + (secs+CountSteppers29041) + ")", SetTimeOutPeriods29041); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors29041)=="undefined") BackColors29041 = ""; if (typeof(ForeColors29041)=="undefined") ForeColors29041= "white"; if (typeof(TargetDates29041)=="undefined") TargetDates29041 = "09/28/2023 10:00:00 PM"; if (typeof(DisplayFormats29041)=="undefined") DisplayFormats29041 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives29041)=="undefined") CountActives29041 = true; if (typeof(FinishMessages29041)=="undefined") FinishMessages29041 = ""; if (typeof(CountSteppers29041)!="number") CountSteppers29041 = -1; if (typeof(LeadingZeros29041)=="undefined") LeadingZeros29041 = true; CountSteppers29041 = Math.ceil(CountSteppers29041); if (CountSteppers29041 == 0) CountActives29041 = false; var SetTimeOutPeriods29041 = (Math.abs(CountSteppers29041)-1)*1000 + 990; puti(BackColors29041, ForeColors29041); var dthens29041 = new Date(TargetDates29041); var dnows29041 = new Date("05/11/2025 9:03:20 PM"); if(CountSteppers29041>0) ddiffs29041 = new Date(dnows29041-dthens29041); else ddiffs29041 = new Date(dthens29041-dnows29041); gsecss29041 = Math.floor(ddiffs29041.valueOf()/1000); CountBacks29041(gsecss29041);