
var elemento;
var http;
var elemento2;
var http2;

	function carregar(url,ele) {
			elemento=ele;
			http=null;
		
			if (window.XMLHttpRequest) {// code for Firefox, Opera, IE7, etc.
				http=new XMLHttpRequest();
		  	}else if (window.ActiveXObject) {// code for IE6, IE5
				http=new ActiveXObject("Microsoft.XMLHTTP");
			}
			if (http!=null) {
				http.onreadystatechange=state_Change;
				http.open("POST",url,true);
				http.send(null);
				//alert(url);
			}else {
				alert("O seu Broweser não suporta XMLHTTP.");
			}
		}
		
		function state_Change(){
			if (http.readyState==4){// 4 = "loaded"
				if (http.status==200){// 200 = "OK"
					document.getElementById(elemento).innerHTML=http.responseText;
					
				}else{
					//alert("Erro ao carregar:" + http.statusText);
				}
			}
		}
		
		function carregar2(url,ele) {
			elemento2=ele;
			http2=null;
		
			if (window.XMLHttpRequest) {// code for Firefox, Opera, IE7, etc.
				http2=new XMLHttpRequest();
		  	}else if (window.ActiveXObject) {// code for IE6, IE5
				http2=new ActiveXObject("Microsoft.XMLHTTP");
			}
			if (http2!=null) {
				http2.onreadystatechange=state_Change2;
				http2.open("POST",url,true);
				http2.send(null);
				//alert(url);
			}else {
				alert("O seu Broweser não suporta XMLHTTP.");
			}
		}
		
		function state_Change2(){
			if (http2.readyState==4){// 4 = "loaded"
				if (http2.status==200){// 200 = "OK"
					document.getElementById(elemento2).innerHTML=http2.responseText;
					
				}else{
					//alert("Erro ao carregar:" + http2.statusText);
				}
			}
		}
