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 (LeadingZeros29059 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks29059(secs) { if (secs < 0) { document.getElementById("cntdwns29059").innerHTML = FinishMessages29059; return; } DisplayStrs29059 = DisplayFormats29059.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs29059 = DisplayStrs29059.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs29059 = DisplayStrs29059.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs29059 = DisplayStrs29059.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns29059").innerHTML = DisplayStrs29059; if (CountActives29059) //alert(SetTimeOutPeriods29059); setTimeout("CountBacks29059(" + (secs+CountSteppers29059) + ")", SetTimeOutPeriods29059); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors29059)=="undefined") BackColors29059 = ""; if (typeof(ForeColors29059)=="undefined") ForeColors29059= "white"; if (typeof(TargetDates29059)=="undefined") TargetDates29059 = "10/04/2023 10:00:00 PM"; if (typeof(DisplayFormats29059)=="undefined") DisplayFormats29059 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives29059)=="undefined") CountActives29059 = true; if (typeof(FinishMessages29059)=="undefined") FinishMessages29059 = ""; if (typeof(CountSteppers29059)!="number") CountSteppers29059 = -1; if (typeof(LeadingZeros29059)=="undefined") LeadingZeros29059 = true; CountSteppers29059 = Math.ceil(CountSteppers29059); if (CountSteppers29059 == 0) CountActives29059 = false; var SetTimeOutPeriods29059 = (Math.abs(CountSteppers29059)-1)*1000 + 990; puti(BackColors29059, ForeColors29059); var dthens29059 = new Date(TargetDates29059); var dnows29059 = new Date("05/11/2025 5:41:14 PM"); if(CountSteppers29059>0) ddiffs29059 = new Date(dnows29059-dthens29059); else ddiffs29059 = new Date(dthens29059-dnows29059); gsecss29059 = Math.floor(ddiffs29059.valueOf()/1000); CountBacks29059(gsecss29059);