    //----------------------------------
    // Create xmlhttp request object
    //----------------------------------
var xmlhttpAdd = false;
   try {
     xmlhttpAdd = new XMLHttpRequest();
	 
	 if (xmlhttpAdd.overrideMimeType) {
		 	xmlhttpAdd.overrideMimeType('text/xml');
	 									}
	 
    } catch (trymicrosoft) {
     try {
       xmlhttpAdd = new ActiveXObject("Msxml2.XMLHTTP");
     } catch (othermicrosoft) {
       try {
         xmlhttpAdd = new ActiveXObject("Microsoft.XMLHTTP");
       } catch (failed) {
         xmlhttpAdd = false;
       }  
     }
   }

       //-----------------------------------------------------------
    // Message handler
	//  - Sends message to script and waits for completion
    //  - On completion, updates page with script output
	//-----------------------------------------------------------
    // url = url to call server-side script
    // resultID = ID of DIV or SPAN element to receive the output
    //-----------------------------------------------------------
function handleMessages (url, resultID) {
  var obj;
  xmlhttpAdd.open("GET", url, true);
  xmlhttpAdd.onreadystatechange=function() {
       if (xmlhttpAdd.readyState==4) {
		   		   
            obj = document.getElementById(resultID);
            obj.innerHTML = xmlhttpAdd.responseText;
		   
	   } 
  }
 xmlhttpAdd.send(null);
 return 0;
}


