<!-- INÍCIO Script Janela Detalhes //-->
function janela_detalhes(url)
	{
	mywin = window.open(url,"window",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=1000,height=600');
	}


<!-- INÍCIO Script do Cadastro //-->
function open_cadastro(url)
	{
	mywin = window.open(url,"window",'toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=530,height=530');
	}


<!-- INÍCIO da verificação dos campos dos formulários -->
<!-- SCRIPT usado para o Site de acesso de Clientes -->
function Form_Validator(theForm) {

//****** CAMPO NOME  ******
  if (theForm.nome.value == false)
   {
     alert("Preencha o campo Nome.");
     theForm.nome.focus();
     theForm.nome.select();
     return (false);
   }

if (isNaN(theForm.nome.value) == false)
  {
    alert("Este campo não aceita números.");
    theForm.nome.focus();
    theForm.nome.select();
    return (false);
  }
  
//****** CAMPO Telefone ******
 if (theForm.telefone.value == false)
   {
     alert("Preencha o campo Telefone.");
     theForm.telefone.focus();
     theForm.telefone.select();
     return (false);
   }
if (theForm.telefone.value != false) {
		// verifica se todos os caracteres digitados são numeros
		var checkOK = "0123456789-";
		var checkStr = theForm.telefone.value;
		var allValid = true;
		var decPoints = 0;
		var allNum = "";
		for (i = 0;  i < checkStr.length;  i++)
		{
			ch = checkStr.charAt(i);
			for (j = 0;  j < checkOK.length;  j++)
			if (ch == checkOK.charAt(j)) break;
			if (j == checkOK.length)
			{
				allValid = false;
				break;
			}
			allNum += ch;
		}
		if (!allValid)
		{
			alert("O campo Telefone só pode conter números e (-), não utilize letras ou caracteres especiais. Ex.:6565-4545");
			theForm.telefone.focus();
			theForm.telefone.select();
			return (false);
		}

//****** CAMPO EMAIL  ******
	var texto = theForm.email.value
	if (texto == false) {
		alert("Preencha o campo E-mail.");
		theForm.email.focus();
		theForm.email.select();
		return(false);
	} else {
	//VERIFICA SE EXISTE "@" NO E-MAIL
	pos = texto.indexOf("@")
	if (pos == -1) {
		alert("Preencha o caractere @");
		theForm.email.focus();
		theForm.email.select();
		return(false);
		} else {
			//VERIFICA SE EXISTE "."(PONTO) NO E-MAIL
			pos = texto.indexOf(".")
			if (pos == -1) {
				alert("Preencha o caractere ponto (.)");
				theForm.email.focus();
				theForm.email.select();
				return(false);
				}
 
//****** CAMPO ASSUNTO ******
  if (theForm.assunto.value == false)
    {
      alert("Selecione um Assunto.");
      theForm.assunto.focus();
      return (false);
   }   
	  }

       }
    }

  }
 										<!-- FIM -->



