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 (LeadingZeros30666 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30666(secs) { if (secs < 0) { document.getElementById("cntdwns30666").innerHTML = FinishMessages30666; return; } DisplayStrs30666 = DisplayFormats30666.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30666 = DisplayStrs30666.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30666 = DisplayStrs30666.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30666 = DisplayStrs30666.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30666").innerHTML = DisplayStrs30666; if (CountActives30666) //alert(SetTimeOutPeriods30666); setTimeout("CountBacks30666(" + (secs+CountSteppers30666) + ")", SetTimeOutPeriods30666); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30666)=="undefined") BackColors30666 = ""; if (typeof(ForeColors30666)=="undefined") ForeColors30666= "white"; if (typeof(TargetDates30666)=="undefined") TargetDates30666 = "07/30/2024 10:00:00 PM"; if (typeof(DisplayFormats30666)=="undefined") DisplayFormats30666 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30666)=="undefined") CountActives30666 = true; if (typeof(FinishMessages30666)=="undefined") FinishMessages30666 = ""; if (typeof(CountSteppers30666)!="number") CountSteppers30666 = -1; if (typeof(LeadingZeros30666)=="undefined") LeadingZeros30666 = true; CountSteppers30666 = Math.ceil(CountSteppers30666); if (CountSteppers30666 == 0) CountActives30666 = false; var SetTimeOutPeriods30666 = (Math.abs(CountSteppers30666)-1)*1000 + 990; puti(BackColors30666, ForeColors30666); var dthens30666 = new Date(TargetDates30666); var dnows30666 = new Date("09/08/2024 2:19:13 AM"); if(CountSteppers30666>0) ddiffs30666 = new Date(dnows30666-dthens30666); else ddiffs30666 = new Date(dthens30666-dnows30666); gsecss30666 = Math.floor(ddiffs30666.valueOf()/1000); CountBacks30666(gsecss30666);