

	function add(url, containerid,session,searchid){
		var anfrage = false
		if (window.XMLHttpRequest) // if Mozilla, Safari etc
			anfrage = new XMLHttpRequest()
		else if (window.ActiveXObject){ // if IE
			try {
				anfrage = new ActiveXObject("Msxml2.XMLHTTP")
			}
		catch (e){
			try{
				anfrage = new ActiveXObject("Microsoft.XMLHTTP")
			}
			catch (e){}
			}
		}
		else
		return false

			anfrage.onreadystatechange=function(){
				changestatus(anfrage, containerid,session,searchid)
			}
			anfrage.open('GET', url, true)
			anfrage.send(null)



	}


	function changestatus(counter, divname,session,searchid){
		if (counter.readyState == 1){
			document.getElementById(divname).innerHTML='<img src=images/loading.gif>';
		}

		if (counter.readyState == 4 && (counter.status==200 || window.location.href.indexOf("http")==-1)){
			document.getElementById(divname).innerHTML=counter.responseText;

			count(session,searchid);
		}

	}



	function count(session,searchid){
		url='count.php?nocache='+ new Date().getTime() +'&s='+ session +'&searchid='+searchid;
		connect(url)

	}


	function doHighlight(){
		new Effect.Highlight('basket');
	}


	function connect(url){


		var counter = false
		if (window.XMLHttpRequest) // if Mozilla, Safari etc
			counter = new XMLHttpRequest()
		else if (window.ActiveXObject){ // if IE
			try {
				counter = new ActiveXObject("Msxml2.XMLHTTP")
			}
		catch (e){
			try{
				counter = new ActiveXObject("Microsoft.XMLHTTP")
			}
			catch (e){}
			}
		}
		else
		return false

			counter.onreadystatechange=function(){
				if (counter.readyState == 4 && (counter.status==200 || window.location.href.indexOf("http")==-1)){
					document.getElementById('basket').innerHTML=counter.responseText
				}
			}
			counter.open('GET', url, true)
			counter.send(null)




	}


