window.onload=init;function init(){var a=document.getElementsByTagName("a");for(i=0;i<a.length;i++)a[i].onfocus=new Function("this.blur()");a=document.getElementsByTagName("input");for(i=0;i<a.length;i++)if(a[i].className=="button")a[i].onfocus=new Function("this.blur()")}function redirect(a){window.location=a}function selectOptionByValue(a,b){for(var c=0;c<b.options.length;){if(b.options[c].value==a){b.selectedIndex=c;return}c++}b.selectedIndex=0}
function removeOptionByValue(a,b){for(var c=0;c<b.options.length;){if(b.options[c].value==a){b.options[c]=null;break}c++}}function getkey(a){return window.event?window.event.keyCode:a?a.which:null}function IncludeJavaScript(a){document.write('<script type="text/javascript" src="'+a+'"><\/script>\r\n')}
function validChars(a,b){var c,d;c=getkey(a);if(c==null)return true;d=String.fromCharCode(c);d=d.toLowerCase();b=b.toLowerCase();if(b.indexOf(d)!=-1)return true;if(c==null||c==0||c==8||c==9||c==13||c==27)return true;return false}
function isDate(a,b,c){var d=[31,29,31,30,31,30,31,31,30,31,30,31];if(a==""&&b==""&&c=="")return false;if(isNaN(a)||isNaN(b)||isNaN(c))return false;if(b<1||b>12)return false;if(c<1753||c>2100)return false;if(b==2&&a==29)if(!(c%4==0&&(c%100!=0||c%400==0)))return false;if(a<1||a>d[b-1])return false;return true}function isEmail(a){var b=a.indexOf("@"),c=a.lastIndexOf("."),d=a.indexOf(" ");a=a.length-1;if(b<1||c<=b+1||c==a||d!=-1)return false;return true}
function isURL(a){if(a.indexOf(" ")!=-1)return false;if(a.indexOf(".")==-1)return false;else if(a.indexOf(".")==0)return false;else if(a.charAt(a.length-1)==".")return false;if(a.indexOf("/")!=-1){a=a.substring(0,a.indexOf("/"));if(a.charAt(a.length-1)==".")return false}if(a.indexOf(":")!=-1){if(a.indexOf(":")==a.length-1)return false;else if(a.charAt(a.indexOf(":")+1)==".")return false;a=a.substring(0,a.indexOf(":"));if(a.charAt(a.length-1)==".")return false}return true}
function isIp(a){ipArray=a.split(".");if(ipArray.length!=4){alert("U dient een correct IP-adres op te geven (xxx.xxx.xxx.xxx)");return false}for(a=0;a<ipArray.length;a++)if(ipArray[a]<0||ipArray[a]>255||ipArray[a]==""){alert("U dient een correct IP-adres op te geven (xxx.xxx.xxx.xxx en xxx < 256)");return false}return true}
function checkZip(a,b){var c,d,e,f,g,h;if(b==null||b=="")return a;h="";d=f=0;for(c=true;f<b.length&&d<=a.length&&c;){g=b.charAt(f);e=a.charAt(d);copy=true;if(g=="9")c=e>="0"&&e<="9";else if(g=="a"||g=="A")c=e>="0"&&e<="9"||e>="a"&&e<="z"||e>="A"&&e<="Z";else if(g=="*"){h+=a.substring(d,a.length);f+=1;d=a.length;copy=false}else if(g!=e){h+=g;f+=1;copy=false}if(c&&copy){h+=e;d+=1;f+=1}}return(c=d==a.length&&f==b.length)?h:null}
function checkFrm(a){var b=document.getElementById("id_frm");for(i=0;i<a.length;i++){tmp=a[i].split("->");if(tmp[0]=="email"&&b[tmp[0]].value!=""&&!isEmail(b[tmp[0]].value)){alert("U dient een geldig e-mailadres in te voeren bij: `"+tmp[1]+"`");b[tmp[0]].focus();return false}if(b[tmp[0]].value==""){alert("U dient het volgende veld in te vullen: `"+tmp[1]+"`");b[tmp[0]].focus();return false}}return true}
function checkFrmGuestbook(a){var b=document.getElementById("id_frm");for(i=0;i<a.length;i++){tmp=a[i].split("->");if(tmp[0]=="email"&&b[tmp[0]].value!=""&&!isEmail(b[tmp[0]].value)){alert("U dient een geldig e-mailadres in te voeren bij: `"+tmp[1]+"`");b[tmp[0]].focus();return false}if(b[tmp[0]].value==""){alert("U dient het volgende veld in te vullen: `"+tmp[1]+"`");b[tmp[0]].focus();return false}}document.getElementById("id_input_id").value=3;return true}
function pagina(a){window.location=siteurl+a}function verwijder(a,b){if(confirm("Weet u zeker dat u wilt verwijderen?"))window.location=siteurl+a+b+"/"}function toint(a){return a<10?"0"+a:a}
function UpdateClock(){if(clockid){clearTimeout(clockid);clockid=0}var a=new Date,b=(new Date(2012,3,9,11,0,0)).getTime()-a.getTime();a=Math.floor(b/1E3/60/60/24);var c=Math.floor((b-a*864E5)/1E3/60/60),d=Math.floor((b-a*864E5-c*36E5)/1E3/60);b=Math.floor((b-a*864E5-c*36E5-d*6E4)/1E3);document.getElementById("id_clock_days").value=a;document.getElementById("id_clock_hours").value=c;document.getElementById("id_clock_minutes").value=d;document.getElementById("id_clock_seconds").value=b;clockid=setTimeout("UpdateClock()",
1E3)}function StartClock(){clockid=setTimeout("UpdateClock()",500)}function KillClock(){if(clockid){clearTimeout(clockid);clockid=0}}function insertImage(a){document.getElementById("id_content").value=document.getElementById("id_content").value+a;document.getElementById("id_content").focus()}function verwijder(a,b){if(confirm("Weet u zeker dat u wilt verwijderen?"))window.location=siteurl+a+b+"/"}
function checkEntryHalveForm(){var a=document.entryform;if(a.distance[a.distance.selectedIndex].value==0){alert("U dient een afstand op te geven.");a.distance.focus();return false}if(a.runnerid[a.runnerid.selectedIndex].value!=0)if(a.email1.value==""){if(a.check1.value=="0"){alert("U heeft geen emailadres opgegeven!\n Dit kunt u doen zodat wij u mogelijk ook per email op de hoogte houden.\nOm u in te schrijven klik nogmaals op inschrijven!");a.email1.focus();a.check1.value=1;return false}}else{if(a.email1.value!=
""&&!isEmail(a.email1.value)){alert("U dient of geen / of een geldig emailadres op te geven.");a.email1.focus();return false}}else{if(a.lastname.value==""){alert("U dient een achternaam op te geven.");a.lastname.focus();return false}else if(a.gender[a.gender.selectedIndex].value=="-"){alert("U dient een geslacht op te geven.");a.gender.focus();return false}if(a.email2.value==""){if(a.check2.value=="0"){alert("U heeft geen emailadres opgegeven!\n Dit kunt u doen zodat wij u mogelijk ook per email op de hoogte houden.\nOm u in te schrijven klik nogmaals op inschrijven!");
a.email2.focus();a.check2.value=1;return false}}else if(a.email2.value!=""&&!isEmail(a.email2.value)){alert("U dient of geen / of een geldig emailadres op te geven.");a.email2.focus();return false}else if(!a.entry.checked){alert("U moet aangeven dat u alle gegevens correct heeft opgegeven");a.entry.focus();return false}}return true};

