function Form_Validator(theForm){

//**********************************
//* Função que chama as validações *
//**********************************

//ADICIONAR AS FUNÇÕES DAS VALIDAÇÕES NESTE ESPAÇO




//****** CAMPO NOME ******
// verifica se o campo está vazio
if (theForm.nome.value == false){
   alert("Preencha o campo Nome.");
   theForm.nome.focus();
   return (false);
}

//****** CAMPO EMAIL ******
// verifica se o campo está vazio
if (theForm.email.value == false){
	alert("Preencha o campo E-mail.");
	theForm.email.focus();
	return (false);
}

//****** CAMPO TELEFONE ******
// verifica se o campo está vazio
if (theForm.telefone.value == false){
	alert("Preencha o campo Telefone.");
	theForm.telefone.focus();
	return (false);
}


var texto = theForm.email.value
// verifica se o campo não está vazio.
if (texto != false) {

//VERIFICA SE EXISTE "@" NO E-MAIL
pos = texto.indexOf("@")
if (pos == -1 || pos < 2){
	alert("Preencha o campo E-mail corretamente.");
	theForm.email.focus();
	theForm.email.select();
	return(false);
	} else {

		//VERIFICA SE EXISTE "."(PONTO) NO E-MAIL
		pos = texto.indexOf(".")
		if (pos == -1 || pos == 0) {
			alert("Preencha o campo E-mail corretamente.");
			theForm.email.focus();
			theForm.email.select();
			return (false);
		} else {

			ponto = texto.indexOf(".")
			tamanho = texto.length;
			parte = texto.substring(ponto,tamanho);

			//VERIFICA SE EXISTE MAIS DE 2 CARACTERES APÓS O "."(PONTO) NO E-MAIL
			if (parte.length < 3){
				alert("Preencha o campo E-mail corretamente.");
				theForm.email.focus();
				theForm.email.select();
				return (false);
			}

		}
	}
}	

//****** CAMPO ASSUNTO ******
// verifica se o campo está vazio
if (theForm.assunto.value == false){
   alert("Preencha o campo Assunto.");
   theForm.assunto.focus();
   return (false);
}

}