
	var xmlHttp = false;

	function getXMLHttpObject ()
	{
		try 
		{
			xmlHttp = new ActiveXObject("Msxml2.XMLHTTP");	 	// Internet Explorer 1ste poging
		} catch (e) {
			try 
			{
				xmlHttp = new ActiveXObject("Microsoft.XMLHTTP"); // Internet Explorer 2de poging
			} catch (e2) {
				xmlHttp = false;
			}	
		}
		if (!xmlHttp && typeof XMLHttpRequest != 'undefined') {
			xmlHttp = new XMLHttpRequest(); 							// Mozilla, Firefox, Opera, ...
		}
	}
	
	function blinkButton()
	{	
		document.getElementById("update").style.backgroundColor = "#FFFF99";
	}

	
	function redirect(url)
	{
		window.location(url);	
	}
	function getRandomProducten()
	{
		getXMLHttpObject();
		var url = "randomProducten.php" + "?dummy=" + Math.random();
		xmlHttp.open("GET", url, false);
		xmlHttp.send(null);
		var antwoord = xmlHttp.responseText;
		document.getElementById("randomProducten").innerHTML = antwoord;
		setTimeout(getRandomProducten,5000);
	}
	
