function chamada(site) {
	var remote = null
	var vertical = window.screen.availHeight;
	var horizontal = window.screen.availWidth;
		remote = window.open( site, '_blank', 'toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=no, leftmargin=0, topmargin=0, width=' + (horizontal - 90) + ', height=' + (vertical - 90) + ', left=20, top=20')

	if (remote != null) {
  		remote.location.href = site
	}
}

function verifica(){
	if (document.alunos.cod_turma.value=="") {
		alert("Informe a turma!")
		return false
	}
}


function validate(){
	
		var temp
			if (document.login.usuario.value=="") {
				alert("O Campo USUÁRIO não está preenchido!")
			return false
			}
		
			if (document.login.senha.value=="") {
				alert("O campo SENHA não está preenchido!")
			return false
			}
		
		return true
	}


function carregarPhp(arquivo, div) {
   //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;
             }
        }
   }
   //se tiver suporte ajax
   if (ajax) {
   	  var d = document.getElementById(div);

	  ajax.open("GET", arquivo, true);
      ajax.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");

      ajax.onreadystatechange = function() {
         //enquanto estiver processando...emite a msg de carregando
         if (ajax.readyState == 1) {
            d.innerHTML = "Carregando...";
         }
         //após ser processado - chama função processXML que vai varrer os dados
         if (ajax.readyState == 4 ) {
            if (ajax.status == 200) {
               d.innerHTML = ajax.responseText;
			   mostrar(div);
            } else {
               d.innerHTML = "Arquivo inválido";
            }
         }
      }
      ajax.send(null);
   }
}

function fechar(div) {
document.getElementById(div).style.display="none";
}

function mostrar(div) {
document.getElementById(div).style.display="block";

}