function entrando(src,cor) 

{
	if (!src.contains(event.fromElement)) 
	{
	  src.bgColor = cor;
	  src.style.cursor = 'hand';
	}
}

function saindo(src,cor) 
{
	if (!src.contains(event.toElement)) 
	{
	  src.bgColor = cor;
	  src.style.cursor = 'default';
	}
}

 hoje = new Date()
 numero_b = 1
 segundos = hoje.getSeconds()

 numero = segundos % numero_b



if (numero == 0){
        banner    = "http://www.gd.com.br/home/imagens/banners/ban_lanhouseperto.gif"
        link      = "http://www.gd.com.br/cgi-local/clickcounter/clickcount.cgi?action=jump&URL=http://www.gd.com.br/home/lanhouse.shtml"
        alvo      = ""
        descricao = "Click aqui!"
        nome_link = ""

}

function abreanuncio(sURL){
newwindow=open(sURL,"gdanuncio","scrollbars=no,toolbar=no,directories=no,menubar=no,resizable=no,status=no,width=451,height=301, top=110, left=250");

}

function abrecontrato(sURL){
newwindow=open(sURL,"gdcontato","scrollbars=yes,toolbar=no,directories=no,menubar=no,resizable=no,status=no,width=310,height=400, top=110, left=450");

}

function abrejanela(sURL){
newwindow=open(sURL,"gdjanela","scrollbars=yes,toolbar=yes,directories=no,menubar=yes,resizable=yes,status=yes,width=400,height=300, top=120, left=350");

}

function abre_suporteaovivo(sURL){
newwindow=open(sURL,"gdaovivo","scrollbars=no,toolbar=no,directories=no,menubar=no,resizable=no,status=no,width=500,height=300, top=120, left=250");

}

function abre_chat_admin(sURL){
newwindow=open(sURL,"gdadmin","scrollbars=no,toolbar=no,directories=no,menubar=no,resizable=yes,status=no,width=500,height=300, top=120, left=250");

}

function abre_mural(sURL){
newwindow=open(sURL,"mural","scrollbars=yes,toolbar=no,directories=no,menubar=no,resizable=yes,status=no,width=500,height=400, top=120, left=250");

}


function abre_pesquisa(sURL){
newwindow=open(sURL,"gdpesquisa","scrollbars=no,toolbar=no,directories=no,menubar=no,resizable=no,status=no,width=310,height=100, top=322, left=400");

}

function abre_jingle(sURL){
newwindow=open(sURL,"jingle","top=230,left=340,scrollbars=no,titlebar=no, toolbar=no,directories=no,menubar=no,resizable=no,status=no,width=150,height=124");

}

function abre_jingle_copa(sURL){
newwindow=open(sURL,"jingle_copa","top=230,left=340,scrollbars=no,titlebar=no, toolbar=no,directories=no,menubar=no,resizable=no,status=no,width=150,height=124");

}

function abre_webcam(sURL){
newwindow=open(sURL,"webcam","top=230,left=340,scrollbars=no,titlebar=no, toolbar=no,directories=no,menubar=no,resizable=no,status=no,width=338,height=280");

}

function abre_hino(sURL){
newwindow=open(sURL,"hino","top=230,left=340,scrollbars=no,titlebar=no, toolbar=no,directories=no,menubar=no,resizable=no,status=no,width=150,height=124");

}

function abre_nando(sURL){
newwindow=open(sURL,"nandolevy","top=100,left=340,scrollbars=no,titlebar=no, toolbar=no,directories=no,menubar=no,resizable=no,status=no,width=402,height=326");

}

function abre_torpedo(sURL){
newwindow=open(sURL,"torpedo","top=100,left=200,scrollbars=no,titlebar=no, toolbar=no,directories=no,menubar=no,resizable=no,status=no,width=273,height=330");

}

function abre_torneio(sURL){
newwindow=open(sURL,"torneio","top=80,left=400,scrollbars=no,titlebar=no, toolbar=no,directories=no,menubar=no,resizable=no,status=no,width=200,height=280");

}

//NEWSLETTERS

function valida_email()
{
  <!--
  if (document.form.address.value.indexOf('@', 0) == -1 || 
  document.form.address.value.indexOf('.', 0) == -1)
  {
    alert("E-mail invalido!");
    document.form.address.value = '';
    document.form.address.focus();
    return false 
  }
}

//WEBMAIL

var dataOK=false

function valida_webmail(){
if (document.Login.userid.value.length == 0 |
   document.Login.passwd.value.length == 0 )
{
      alert("Digite seu E-mail e Login!")
   return false}

   else {
      return true}
}

// TESTA CPF

function submete () {

if (document.cadastro.usuario.value.indexOf('@', 0) == -1 || 
  document.cadastro.usuario.value.indexOf('.', 0) == -1)
  {
    alert("E-mail invalido!");
    document.cadastro.usuario.value = '';
    document.cadastro.usuario.focus();
    return false 
  }

   if (checaCPF(document.cadastro.cpf.value)) {
     document.cadastro.submit();
   }
   else {
	 	 errors="1";
     if (errors) alert('Digite corretamente o CPF');
		 document.MM_returnValue = (errors == '');
     return false 
   }
 }

 function checaCPF (CPF) {
	if (CPF.length != 11 || CPF == "00000000000" || CPF == "11111111111" ||
		CPF == "22222222222" ||	CPF == "33333333333" || CPF == "44444444444" ||
		CPF == "55555555555" || CPF == "66666666666" || CPF == "77777777777" ||
		CPF == "88888888888" || CPF == "99999999999")
		return false;
	soma = 0;
	for (i=0; i < 9; i ++)
		soma += parseInt(CPF.charAt(i)) * (10 - i);
	resto = 11 - (soma % 11);
	if (resto == 10 || resto == 11)
		resto = 0;
	if (resto != parseInt(CPF.charAt(9)))
		return false;
	soma = 0;
	for (i = 0; i < 10; i ++)
		soma += parseInt(CPF.charAt(i)) * (11 - i);
	resto = 11 - (soma % 11);
	if (resto == 10 || resto == 11)
		resto = 0;
	if (resto != parseInt(CPF.charAt(10)))
		return false;

        	return true;
 }



