var ajaxdestination="";var rnd_nr=Math.random()*1234567;var status;function noCache(a){return a.concat(/\?/.test(a)?"&":"?","noCache=",rnd_nr)}function getdata(c,a){try{xmlhttp=window.XMLHttpRequest?new XMLHttpRequest():new ActiveXObject("Microsoft.XMLHTTP")}catch(b){}document.getElementById(a).innerHTML="<center><br><img src='images/ajax-loader.gif'><br><br></center>";ajaxdestination=a;xmlhttp.open("GET",c);xmlhttp.onreadystatechange=triggered;xmlhttp.send(null);return false}function triggered(){if(xmlhttp.readyState==4){if(xmlhttp.status==200){document.getElementById(ajaxdestination).innerHTML=xmlhttp.responseText;return true}}return false}function createRequestObject(){var a;if(window.XMLHttpRequest){a=new XMLHttpRequest()}else{if(window.ActiveXObject){a=new ActiveXObject("Microsoft.XMLHTTP")}else{a=NULL;alert("Probleem met het aanmaken van hetXMLHttpRequest object")}}return a}var http=createRequestObject();var aDiv=new aDiv();function setDiv(a){this.theDiv=a}function getCurrentDiv(){if(this.theDiv!=""){return this.theDiv}else{alert("Geen div geset")}}function aDiv(a){this.theDiv=a||"";this.set=setDiv;this.getCurrent=getCurrentDiv}andersx=0;loadTekst="";function AJAXcheckVeld(c,g,a,b,e){andersx=e;if(b==""){var f="AJAXcheckVeld.php"}else{f=b}if(g.length!=a.length){alert("sendRequest: arg3 and arg4 != length")}else{var d=Math.random()*5;var h="noCache="+d+"&";aDiv.set(c);for(i=0;i<g.length;i++){waarde=a[i];if(g[i]=="loading"){loadTekst=a[i]}h+=g[i]+"="+a[i]+"&"}h=SearchAndReplace(h," ","%20");http.open("POST",f,true);http.setRequestHeader("Content-Type","application/x-www-form-urlencoded");http.onreadystatechange=handleResponse;http.send(h)}}function AJAXsendURL(a,b){if(a==""){var d="AJAXcheckVeld.php"}else{d=a}var c=Math.random()*5;var e=d+"&noCache="+c;aDiv.set(b);http.open("post",e,false);http.onreadystatechange=handleResponse;http.send(null)}function handleResponse(){if(http.readyState==4&&http.status==200){if(http.responseText){document.getElementById(aDiv.getCurrent()).innerHTML=http.responseText}else{document.getElementById(aDiv.getCurrent()).innerHTML=""}}else{if(andersx==1){document.getElementById("meerFotosLoading").innerHTML=""}else{document.getElementById(aDiv.getCurrent()).innerHTML=""+loadTekst;loadTekst=""}}};

