
function getHTTPObject(){
	    if (window.ActiveXObject) 
		    return new ActiveXObject("Microsoft.XMLHTTP");
        else if (window.XMLHttpRequest)
			return new XMLHttpRequest();
		else { 
			alert("Your browser does not support AJAX.");
			return null;
		}
	}

function createRequestObject() {
	// find the correct xmlHTTP, works with IE, FF and Opera
	var xmlhttp;
	try {
  	xmlhttp=new ActiveXObject("Msxml2.XMLHTTP");
  }
  catch(e) {
    try {
    	xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
    }
    catch(e) {
    	xmlhttp=null;
    }
  }
  if(!xmlhttp&&typeof XMLHttpRequest!="undefined") {
  	xmlhttp=new XMLHttpRequest();
  }
	return  xmlhttp;
}

	
	// Change the value of the outputText field
   	function setOutput(){
    	if(httpObject.readyState == 4){
			document.getElementById('advCalendar').innerHTML
				= httpObject.responseText;
		}
    }
	
	// Implement business logic
    function doWork(dat){
		httpObject = false;
		httpObject = createRequestObject()
   //		httpObject = getHTTPObject();
   		if (httpObject != null) {
        	httpObject.open("GET", "advcal.php?dat="+dat, true);
			
			httpObject.onreadystatechange = setOutput;
			httpObject.send(null);
		}
	}
	
	var httpObject = null;

	
function simplePreload()
{ 
  var args = simplePreload.arguments;
  document.imageArray = new Array(args.length);
  for(var i=0; i<args.length; i++)
  {
    document.imageArray[i] = new Image;
    document.imageArray[i].src = args[i];
  }
}
function mouseOver(i,bild)
{
document.getElementById(i).src = bild + "_over.png"
}
function mouseOut(i,bild)
{
document.getElementById(i).src = bild + ".png"
}
function mouseDown(i,bild)
{
document.getElementById(i).src = bild + "_push.png"
}
function mouseOverDetail(i,bild)
{
document.getElementById(i).src = bild
}

