function createRequestObject() {  //Get the right xmlHTTP, including IE, FF and Opera, try and catch for errors error catching
	var xmlhttp;
try
    {
        xmlhttp=new ActiveXObject("Msxml2.XMLHTTP");
    }
    catch(e)
    {
        try
        {
             xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
        }
        catch(f)
        {
             xmlhttp=null;
        }
    }
    if(! xmlhttp&&typeof XMLHttpRequest!="undefined")
    {
         xmlhttp=new XMLHttpRequest();
    }
	return  xmlhttp;
}
var http = createRequestObject(); //make the AJAX thingy
var timeoutholder=null; //this variable holds the timeouts which wait between keypresses
function sndReq(search) { //this function asks for the functions
	search=escape(search);  //escape for URLs


try{
    http.open('get', '../private/search_addon.asp?action=1&zoekterm='+search);  //sends request
    http.onreadystatechange = handleResponse; //ensures the response is handled by the correct function
    http.send(null);}
	catch(e){}
	finally{}

}

function handleResponse() {
	try{
    if((http.readyState == 4)&& (http.status == 200)){
        var response = http.responseText;
		document.getElementById("matches").innerHTML = response; //Fill in response
		document.getElementById("loading").innerHTML = ""; //Fill in response
		} else {
		document.getElementById("loading").innerHTML = "zoeken..."; //Fill in response
		}
    }

catch(e){}
finally{}

}