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 (LeadingZeros30133 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30133(secs) { if (secs < 0) { document.getElementById("cntdwns30133").innerHTML = FinishMessages30133; return; } DisplayStrs30133 = DisplayFormats30133.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30133 = DisplayStrs30133.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30133 = DisplayStrs30133.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30133 = DisplayStrs30133.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30133").innerHTML = DisplayStrs30133; if (CountActives30133) //alert(SetTimeOutPeriods30133); setTimeout("CountBacks30133(" + (secs+CountSteppers30133) + ")", SetTimeOutPeriods30133); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30133)=="undefined") BackColors30133 = ""; if (typeof(ForeColors30133)=="undefined") ForeColors30133= "white"; if (typeof(TargetDates30133)=="undefined") TargetDates30133 = "04/19/2024 11:00:00 PM"; if (typeof(DisplayFormats30133)=="undefined") DisplayFormats30133 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30133)=="undefined") CountActives30133 = true; if (typeof(FinishMessages30133)=="undefined") FinishMessages30133 = ""; if (typeof(CountSteppers30133)!="number") CountSteppers30133 = -1; if (typeof(LeadingZeros30133)=="undefined") LeadingZeros30133 = true; CountSteppers30133 = Math.ceil(CountSteppers30133); if (CountSteppers30133 == 0) CountActives30133 = false; var SetTimeOutPeriods30133 = (Math.abs(CountSteppers30133)-1)*1000 + 990; puti(BackColors30133, ForeColors30133); var dthens30133 = new Date(TargetDates30133); var dnows30133 = new Date("04/29/2024 7:06:36 PM"); if(CountSteppers30133>0) ddiffs30133 = new Date(dnows30133-dthens30133); else ddiffs30133 = new Date(dthens30133-dnows30133); gsecss30133 = Math.floor(ddiffs30133.valueOf()/1000); CountBacks30133(gsecss30133);