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 (LeadingZeros31904 && s.length < 2) s = "0" + s; if (seconds == 1) { var classString = "count-seconds"; } else { var classString = ""; } return "" + s + ""; } function CountBacks31904(secs) { if (secs < 0) { document.getElementById("cntdwns31904").innerHTML = FinishMessages31904; return; } DisplayStrs31904 = DisplayFormats31904.replace(/%%D%%/g, calcage(secs,86400,100000,0)); DisplayStrs31904 = DisplayStrs31904.replace(/%%H%%/g, calcage(secs,3600,24,1)); DisplayStrs31904 = DisplayStrs31904.replace(/%%M%%/g, calcage(secs,60,60,0)); DisplayStrs31904 = DisplayStrs31904.replace(/%%S%%/g, calcage(secs,1,60,0,1)); document.getElementById("cntdwns31904").innerHTML = DisplayStrs31904; if (CountActives31904) //alert(SetTimeOutPeriods31904); setTimeout("CountBacks31904(" + (secs+CountSteppers31904) + ")", SetTimeOutPeriods31904); } function puti(backcolor, forecolor) { document.write("
"); } if (typeof(BackColors31904)=="undefined") BackColors31904 = ""; if (typeof(ForeColors31904)=="undefined") ForeColors31904= "white"; if (typeof(TargetDates31904)=="undefined") TargetDates31904 = "04/02/2025 11:00:00 PM"; if (typeof(DisplayFormats31904)=="undefined") DisplayFormats31904 = " %%H%%:%%M%%:%%S%%"; if (typeof(CountActives31904)=="undefined") CountActives31904 = true; if (typeof(FinishMessages31904)=="undefined") FinishMessages31904 = ""; if (typeof(CountSteppers31904)!="number") CountSteppers31904 = -1; if (typeof(LeadingZeros31904)=="undefined") LeadingZeros31904 = true; CountSteppers31904 = Math.ceil(CountSteppers31904); if (CountSteppers31904 == 0) CountActives31904 = false; var SetTimeOutPeriods31904 = (Math.abs(CountSteppers31904)-1)*1000 + 990; puti(BackColors31904, ForeColors31904); var dthens31904 = new Date(TargetDates31904); var dnows31904 = new Date("04/02/2025 4:03:31 AM"); if(CountSteppers31904>0) ddiffs31904 = new Date(dnows31904-dthens31904); else ddiffs31904 = new Date(dthens31904-dnows31904); gsecss31904 = Math.floor(ddiffs31904.valueOf()/1000); CountBacks31904(gsecss31904);