   function testaAjax() {
      //verifica se o browser tem suporte a ajax
	  try {
         ajax = new ActiveXObject("Microsoft.XMLHTTP");
      } 
      catch(e) {
         try {
            ajax = new ActiveXObject("Msxml2.XMLHTTP");
         }
	     catch(ex) {
            try {
               ajax = new XMLHttpRequest();
            }
	        catch(exc) {
               //alert("Esse browser não tem recursos para uso do Ajax");
               ajax = null;
            }
         }
      }
	  return ajax;   
   }
	 window.onload = function() {
		  if(testaAjax()!=null) {
				 ajax.open("POST", "addresb.php", true);
				 ajax.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
			
				 var params = "x="+screen.width+"&y="+screen.height;
				 ajax.send(params);
		  } 
	}  
