//Carregando arquivos XML
function loadXMLDoc(f){
	var xmlDoc;
	// code for IE
	if (window.ActiveXObject){xmlDoc=new ActiveXObject("Microsoft.XMLDOM");}
	// Mozilla, Firefox, Opera, etc.
	else if (document.implementation && document.implementation.createDocument){
		xmlDoc=document.implementation.createDocument("","",null);
	}
	xmlDoc.async=false;
	xmlDoc.load(f);
	return(xmlDoc);
}

//objeto HttpRequest(ajax)
function objAjax(){
	try{return new XMLHttpRequest()}catch(e){
		try{return new ActiveXObject("Msxml2.XMLHTTP")}
		catch(e){return new ActiveXObject("Microsoft.XMLHTTP")}
	}
	return null;
}