function loadXMLDoc(dname) 
			{
			try //Internet Explorer
			  {
			  xmlDoc=new ActiveXObject("Microsoft.XMLDOM");
			  }
			catch(e)
			  {
			  try //Firefox, Mozilla, Opera, etc.
			    {
			    xmlDoc=document.implementation.createDocument("","",null);
			    }
			  catch(e) {alert(e.message)}
			  }
			try 
			  {
			  xmlDoc.async=false;
			  xmlDoc.load(dname);
			  return(xmlDoc);
			  }
			catch(e) {alert(e.message)}
			return(null);
			}

			function returnXML(txt) {
				if (document.implementation && document.implementation.createDocument) {
					xmlDoc = document.implementation.createDocument("", "", null);
					parser=new DOMParser();
					xmlDoc=parser.parseFromString(txt,"text/xml");
				}
			  // MSIE uses ActiveX
				else if (window.ActiveXObject) {
					xmlDoc = new ActiveXObject("Msxml2.DOMDocument");
					xmlDoc.async = "false";
					xmlDoc.loadXML(txt);
	  			}
				
				return xmlDoc;
			}