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 (LeadingZeros29490 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks29490(secs) { if (secs < 0) { document.getElementById("cntdwns29490").innerHTML = FinishMessages29490; return; } DisplayStrs29490 = DisplayFormats29490.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs29490 = DisplayStrs29490.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs29490 = DisplayStrs29490.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs29490 = DisplayStrs29490.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns29490").innerHTML = DisplayStrs29490; if (CountActives29490) //alert(SetTimeOutPeriods29490); setTimeout("CountBacks29490(" + (secs+CountSteppers29490) + ")", SetTimeOutPeriods29490); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors29490)=="undefined") BackColors29490 = ""; if (typeof(ForeColors29490)=="undefined") ForeColors29490= "white"; if (typeof(TargetDates29490)=="undefined") TargetDates29490 = "12/04/2023 10:00:00 PM"; if (typeof(DisplayFormats29490)=="undefined") DisplayFormats29490 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives29490)=="undefined") CountActives29490 = true; if (typeof(FinishMessages29490)=="undefined") FinishMessages29490 = ""; if (typeof(CountSteppers29490)!="number") CountSteppers29490 = -1; if (typeof(LeadingZeros29490)=="undefined") LeadingZeros29490 = true; CountSteppers29490 = Math.ceil(CountSteppers29490); if (CountSteppers29490 == 0) CountActives29490 = false; var SetTimeOutPeriods29490 = (Math.abs(CountSteppers29490)-1)*1000 + 990; puti(BackColors29490, ForeColors29490); var dthens29490 = new Date(TargetDates29490); var dnows29490 = new Date("05/11/2025 2:15:20 PM"); if(CountSteppers29490>0) ddiffs29490 = new Date(dnows29490-dthens29490); else ddiffs29490 = new Date(dthens29490-dnows29490); gsecss29490 = Math.floor(ddiffs29490.valueOf()/1000); CountBacks29490(gsecss29490);