// JavaScript Document
function voir(){
	document.getElementById("test").style.visibility='visible';
	}

var re=RegExp("^([a-zA-Z0-9_-])+([.]?[a-zA-Z0-9_-]{1,})*@([a-zA-Z0-9-_]{2,}[.])+[a-zA-Z]{2,3}$");
function sendtofriend(){
		
		


		var t1 = document.getElementById('me').value;
		var t2 = document.getElementById('eme').value;
		var t3 = document.getElementById('you').value;
		var t4 = document.getElementById('eyou').value;
		var t5 = document.getElementById('text').value;
		
		if (t1 == ""  || t2 == ""  || t3 == ""  || t4 == ""  || t5 == "" ){
			alert('Merci de remplire tous les champs');
			return false;
		}
		else if (!re.test(t2)){
			alert('Votre email est invalide');
			return false;
		}
		else if (!re.test(t4)){
			alert('Email du destinataire invalide');
			return false;
		}
		else{
		return true;
				
		}

}

function inscr1(){
	
	
	
	if ($('#socie').val() == ""   || $('#email').val() == ""){
			alert('Merci de remplire tous les champs');
			return false;
		}
		else if (!re.test($('#email').val())){
			alert('Votre email est invalide');
			return false;
		}
	else{return true;}
}

function inscr2(){
		<!--else if (!re.test($('#t20').val())){
		<!--	alert('Votre email est invalide');
		<!--	return false;
		<!--}-->
	/*	if (isNaN($('#t7').val())){
			alert('Tel invalide Demandeur');
			return false;
		}
		else if ( isNaN( $('#t18').val() ) ){
			alert('Tel invalide Entreprise');
			return false;
			
		}
	else{*/
   
	
// }

var ipp=document.getElementById('t25').value;
if(ipp!=''){
var strb=ipp.split('.');
var strbs=strb[1];

if(strbs!='jpg' || strbs!='png' || strbs!='gif' || strbs!='jpeg'){
    alert('Le format de votre logo est invalide !!!'+ipp);
    return false;
}else{
return true;}}
}

function pub(){
	if (	$('#t1').val() == ""   ||
			$('#t3').val() == ""   ||
			$('#t5').val() == ""   ||
			$('#t6').val() == ""   ||
			$('#t12').val() == ""  ){
			alert('Merci de remplire les champs obligatoir');
			return false;
	}
	else if (!re.test($('#t5').val())){
			alert('Votre email est invalide');
			return false;
		}
	else if ( isNaN( $('#t6').val() ) ){
			alert('Tel invalide');
			return false;
		}
	else{return true;}
}
function ct(){
	if (	$('#t1').val() == ""   ||
			$('#t5').val() == ""   ||
			$('#t12').val() == ""  ||
			$('#t6').val()==""){
			alert('Merci de remplire les champs obligatoir');
			return false;
	}
	else if (!re.test($('#t5').val())){
			alert('Votre email est invalide');
			return false;
		}
	else if ( isNaN( $('#t6').val() ) ){
			alert('Tel invalide');
			return false;
		}
	else{return true;}
}
function nws(){
	
	if (!re.test(document.getElementById('newstext').value)){
			alert('Votre email est invalide');
			return false;
		}else{return true;}
}
