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 (LeadingZeros30304 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks30304(secs) { if (secs < 0) { document.getElementById("cntdwns30304").innerHTML = FinishMessages30304; return; } DisplayStrs30304 = DisplayFormats30304.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs30304 = DisplayStrs30304.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs30304 = DisplayStrs30304.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs30304 = DisplayStrs30304.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns30304").innerHTML = DisplayStrs30304; if (CountActives30304) //alert(SetTimeOutPeriods30304); setTimeout("CountBacks30304(" + (secs+CountSteppers30304) + ")", SetTimeOutPeriods30304); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors30304)=="undefined") BackColors30304 = ""; if (typeof(ForeColors30304)=="undefined") ForeColors30304= "white"; if (typeof(TargetDates30304)=="undefined") TargetDates30304 = "04/28/2024 10:00:00 PM"; if (typeof(DisplayFormats30304)=="undefined") DisplayFormats30304 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives30304)=="undefined") CountActives30304 = true; if (typeof(FinishMessages30304)=="undefined") FinishMessages30304 = ""; if (typeof(CountSteppers30304)!="number") CountSteppers30304 = -1; if (typeof(LeadingZeros30304)=="undefined") LeadingZeros30304 = true; CountSteppers30304 = Math.ceil(CountSteppers30304); if (CountSteppers30304 == 0) CountActives30304 = false; var SetTimeOutPeriods30304 = (Math.abs(CountSteppers30304)-1)*1000 + 990; puti(BackColors30304, ForeColors30304); var dthens30304 = new Date(TargetDates30304); var dnows30304 = new Date("05/04/2024 7:10:43 PM"); if(CountSteppers30304>0) ddiffs30304 = new Date(dnows30304-dthens30304); else ddiffs30304 = new Date(dthens30304-dnows30304); gsecss30304 = Math.floor(ddiffs30304.valueOf()/1000); CountBacks30304(gsecss30304);