// JavaScript Document

			//produits peaux sèches
			//-------------------------------------------------------------------------
			produitsPeauxSeches = new Array();
			produitsPeauxSeches[0] = 'Con agua destilada<br/> meliloto';
			produitsPeauxSeches[1] = 'Concentrado<br/> Nutritivo';
			produitsPeauxSeches[2] = 'Crema Confort<br/> Reparadora';
			produitsPeauxSeches[3] = 'Crema Suave<br/> Reparadora';
			produitsPeauxSeches[4] = 'Cuidado Noche<br/> Nutri Activo';
			produitsPeauxSeches[5] = 'Exfoliante Corporal<br>al Jabón Negro';
			produitsPeauxSeches[6] = 'Mascarilla<br/>Nutri-Intensiva';
			produitsPeauxSeches[7] = 'Aceite Seco<br/> Regenerante<br/> Corporal';
			produitsPeauxSeches[8] = 'Crema Sedosa<br/> Manos y <br/>U&ntilde;as ';
			produitsPeauxSeches[9] = 'Nutrici&oacute;n y<br/> Firmeza';


			//produits anti-age
			//-------------------------------------------------------------------------
			produitsAntiAge = new Array();
			produitsAntiAge[0] = 'Con agua destilada<br/> meliloto';
			produitsAntiAge[1] = 'Concentrado<br/> Nutritivo';
			produitsAntiAge[2] = 'Cuidado Tensor<br/> Redensificante';
			produitsAntiAge[3] = 'Cuidado Noche<br/> Nutri Activo';
			produitsAntiAge[4] = 'Cuidado Tensor<br/> Redensificante<br/> Ojos-Labios';
			produitsAntiAge[5] = 'Mascarilla<br/>Nutri-Intensiva';
			produitsAntiAge[6] = 'Aceite Seco<br/> Regenerante<br/> Corporal';
			produitsAntiAge[7] = 'Crema Sedosa<br/> Manos y<br/> Uñas';
			produitsAntiAge[8] = 'Nutrici&oacute;n y<br/> Firmeza';


			//produits anti-rides
			//-------------------------------------------------------------------------
			produitsAntiRides = new Array();
			produitsAntiRides[0] = 'Con agua destilada<br/> meliloto';
			produitsAntiRides[1] = 'Serum Antiarrugas<br/> Reparador';
			produitsAntiRides[2] = 'Cremas';
			produitsAntiRides[3] = 'Cuidado<br/>de Noche';
			produitsAntiRides[4] = 'Cuidado<br/> Antiarrugas<br/> Ojos';
			produitsAntiRides[5] = 'Mascarilla<br/> Antiarrugas<br/> Rejuvenecedora';
			produitsAntiRides[6] = 'Patchs<br>Antiarrugas<br/> Alisantes Todo<br/> tipo de pieles';
			produitsAntiRides[7] = 'Emulsión';
			produitsAntiRides[8] = 'Crema<br>SPF 15';

			//produits énergie
			//-------------------------------------------------------------------------
			produitsEnergie = new Array();
			produitsEnergie[0] = 'Con agua destilada<br/> meliloto';
			produitsEnergie[1] = 'Elixir Alisante Nueva Piel<br/> Sobreactivador de la luminosidad';
			produitsEnergie[2] = 'Crema Ligera<br/> Hidra-Energizante SPF 15';
			produitsEnergie[3] = 'Crema Aterciopelada<br/> Hidra-Energizante SPF 15';
			produitsEnergie[4] = 'Cuidado Ojos<br/> Frescor Aatifatiga';


			//produits anti-taches
			//-------------------------------------------------------------------------
			produitsAntiTaches = new Array();
			produitsAntiTaches[0] = 'Con agua destilada<br/> meliloto';
			produitsAntiTaches[1] = 'Suero Intensivo<br/> Unificador ';
			produitsAntiTaches[2] = 'Crema Protecci&oacute;n<br> Anti-manchas SPF15' ;
			produitsAntiTaches[3] = 'Concentrado Corrector<br/> Antimanchas ';


            //produits hydratation
			//-------------------------------------------------------------------------
			produitsHydratation = new Array();
			produitsHydratation[0] = 'Con agua destilada<br/> meliloto';
			produitsHydratation[1] = 'Elixir<br>Hidratante<br>Intensivo';
			produitsHydratation[2] = 'Gel-crema<br>Frescor<br>Hidratante';
			produitsHydratation[3] = 'Crema<br>Fresca<br>Hidratante   ';
			produitsHydratation[4] = 'Cuidado<br>Hidra-Protector<br>SPF 15';
			produitsHydratation[5] = 'Mascarilla<br>Hidratante<br>Exprés ';


			//produits peaux grasses
			//-------------------------------------------------------------------------
			produitsPeauxGrasses = new Array();
			produitsPeauxGrasses[0] = 'Con agua destilada<br/> meliloto';
			produitsPeauxGrasses[1] = 'Gel limpiador<br/> Purificante';
			produitsPeauxGrasses[2] = 'Loci&oacute;n Tónica<br/> Astringente';
			produitsPeauxGrasses[3] = 'Gel Crema<br/>Reequilibrante';
			produitsPeauxGrasses[4] = 'Concentrado Local<br/> Anti-imperfecciones';
			produitsPeauxGrasses[5] = 'Mascarilla Exfoliante<br/> Purificante 3 en 1';
			produitsPeauxGrasses[6] = 'Cuidado Saneante<br/> Renovador';


			//produits démaquillage
			//-------------------------------------------------------------------------
			produitsDemaquillage = new Array();
			produitsDemaquillage[0] = 'Gel Limpiador<br> Espumante';
			produitsDemaquillage[1] = 'Espuma Limpiadora<br> Desmaquillante ';
			produitsDemaquillage[2] = 'Leche<br> desmaquillante ';
			produitsDemaquillage[3] = 'Agua Limpiadora<br> Desmaquillante';
			produitsDemaquillage[4] = '2 en 1<br/> desmaquillante ';
			produitsDemaquillage[5] = 'Loci&oacute;n T&oacute;nica';
			produitsDemaquillage[6] = 'Desmaquillante<br/> de ojos';
			produitsDemaquillage[7] = 'Gel Exfoliante';


			//produits solaire1
			//-------------------------------------------------------------------------
			produitsSolaires1 = new Array();
			produitsSolaires1[0] = 'Complemento Alimenticio';
			produitsSolaires1[1] = 'Crema Facial<br/>SPF50';
			produitsSolaires1[2] = 'Bálsamo Facial Reparador<br>para Despu&eacute;s del Sol';
			produitsSolaires1[3] = 'Leche para<br> Después del Sol';
			produitsSolaires1[4] = 'Gel de Ducha para<br/> Después del Sol';
			produitsSolaires1[5] = 'Gel-crema<br> Autobronceador';
			produitsSolaires1[6] = 'Gel-crema<br> Después del Sol. Cara';



			mentionSolaire = 'Seg&uacute;n su comodidad';

			//produits solaire2
			//-------------------------------------------------------------------------
			produitsSolaires2 = new Array();
			produitsSolaires2[0] = 'Complemento Alimenticio';
			produitsSolaires2[1] = 'Spray Cara<br/>y Cuerpo<br> SPF 50 o 30';
			produitsSolaires2[2] = 'Stick Zonas Frágiles<br>SPF 50';
			produitsSolaires2[3] = 'Leche Cuerpo<br/>SPF 50 o 30';
			produitsSolaires2[4] = 'Bálsamo Facial Reparador<br>para Despu&eacute;s del Sol';
			produitsSolaires2[5] = 'Leche para<br> Despu&eacute;s del Sol';
			produitsSolaires2[6] = 'Gel de Ducha para<br/> Después del Sol';
			produitsSolaires2[7] = 'Gel-crema<br> Autobronceador';
			produitsSolaires2[8] = 'Crema<br/>SPF 30';
			produitsSolaires2[9] = 'Fluido no Graso<br/>SPF 30';
			produitsSolaires2[10] ='Compacto Luminoso<br>SPF 30';


			//produits solaire3
			//-------------------------------------------------------------------------
			produitsSolaires3 = new Array();
			produitsSolaires3[0] = 'Complemento Alimenticio';
			produitsSolaires3[1] = 'Spray<br/>SPF 20';
			produitsSolaires3[2] = 'Crema Facial<br/>SPF 20';
			produitsSolaires3[3] = 'Leche<br/>SPF 20';
			produitsSolaires3[4] = 'Bálsamo Facial Reparador<br>para Despu&eacute;s del Sol';
			produitsSolaires3[5] = 'Leche para<br> Despu&eacute;s del Sol';
			produitsSolaires3[6] = 'Gel de Ducha para<br/> Despu&eacute;s del Sol';
			produitsSolaires3[7] = 'Gel-crema<br> Autobronceador';
			produitsSolaires3[8] = 'Gel Fundente<br/>SPF 15';
			produitsSolaires3[9] = 'Aceite Seco Sedoso<br/>SPF 15';
			produitsSolaires3[10] = 'Fluido No Graso<br/>SPF 20';
			produitsSolaires3[11] = 'Gel-crema Frescor<br/>Despu&eacute;s del Sol';
			
			//produits solaire4
			//-------------------------------------------------------------------------
			produitsSolaires4 = new Array();
			produitsSolaires4[0] = 'Food<br/>Supplement';
			produitsSolaires4[1] = 'Spray Cara y Cuerpo<br>SPF 10';
			produitsSolaires4[2] = 'Gel Crema Frescor<br>Después del sol';
			produitsSolaires4[3] = 'Bálsamo Facial Reparador<br>para Despu&eacute;s del Sol';
			produitsSolaires4[4] = 'Gel-Crema Autobronceado';
			produitsSolaires4[5] = 'Leche para<br>Desqués del Sol';
			produitsSolaires4[6] = 'Gel de Ducha para<br>Desqués del Sol';
		

function removeAlt() {

	for ( var i = 0; i< document.images.length; i++ ) 
	{
	
		if ( typeof( document.images[i].alt ) == 'string' ) {
		
		document.images[i].alt = "";
		
		}
	
		if ( typeof( document.images[i].title ) == 'string' ) {
		
		document.images[i].title = "";
		
		}
	
	}

}


function openMenu(id){

	//sous menu
    if((id.toString()).indexOf(".") != -1 ){

		var cut = (id.toString()).split(".");
		var menu = cut[0];
		var smenu = cut[1];

		for(j=1; j<3;j++){

			document.getElementById('sMenu' + menu + '.' + j).style.display = 'none';

		}

		document.getElementById('sousMenu3').style.display = 'block';

	    document.getElementById('sMenu' + menu).style.display = 'block';
		document.getElementById('sMenu' + id).style.display = 'block';
		document.getElementById('rub' + menu).className = 'rub'+menu+'On';
		document.getElementById('sRub' + id).className = 'menuItemClick';

	}

	//menu simple
	else{

		if(id==3){
			document.getElementById('sousMenu3').style.display = 'block';
		}


		document.getElementById('sMenu' + id).style.display = 'block';
		document.getElementById('rub' + id).className = 'rub'+id+'On';
	}
}

function closeMenu(id){

	document.getElementById( 'sMenu' + id ).style.display = 'none';
	document.getElementById('sousMenu3').style.display = 'none';

	if((id.toString()).indexOf(".") == -1 ){

		document.getElementById('rub'+id).className = 'rub'+id;

	}
	else{

		document.getElementById('sRub' + id).className = 'menuItem';


	}

	for(i= 1; i < 7 ; i++){

		if(i != 4){

			document.getElementById( 'sMenu' + i ).style.display = 'none';
		}
	}
}


function ongletInit(){
	window.document.getElementById( "onglet1_txt" ).style.display = "block";
	if ( window.document.getElementById( "onglet2_img" ) != null ){
	window.document.getElementById( "onglet2_txt" ).style.display = "none";
	}
	window.document.getElementById( "onglet3_txt" ).style.display = "none";
	if ( window.document.getElementById( "onglet4_img" ) != null ){
		window.document.getElementById( "onglet4_txt" ).style.display = "none";
	}
}

function onglet( id, type )
{



		bt = window.document.getElementById( id + "_img" );
		txt = window.document.getElementById( id + "_txt" );




			if ( type == "out" ){
				if ( txt.style.display == "none" || txt.style.display == "undefined" || txt.style.display == "" ){

					bt.style.visibility = 'hidden';

				}

			}else if ( type == "over" ){

				bt.style.visibility = 'visible';

			}



}

function ongletClick ( id ) {

	bt = window.document.getElementById( id + "_img" );
	txt = window.document.getElementById( id + "_txt" );

	window.document.getElementById( "onglet1_img" ).style.visibility = "hidden";

	if ( window.document.getElementById( "onglet2_img" ) != null ){
	window.document.getElementById( "onglet2_img" ).style.visibility = "hidden";
	}
	window.document.getElementById( "onglet3_img" ).style.visibility = "hidden";

	if ( window.document.getElementById( "onglet4_img" ) != null ){
		window.document.getElementById( "onglet4_img" ).style.visibility = "hidden";
	}

	window.document.getElementById( "onglet1_txt" ).style.display = "none";


	if ( window.document.getElementById( "onglet2_img" ) != null ){
		window.document.getElementById( "onglet2_txt" ).style.display = "none";
	}

	window.document.getElementById( "onglet3_txt" ).style.display = "none";

	if ( window.document.getElementById( "onglet4_img" ) != null ){
		window.document.getElementById( "onglet4_txt" ).style.display = "none";
	}

	bt.style.visibility = "visible";
	txt.style.display = "block";

}

function navGammeSolaire(id){


	 for(i=1; i<5; i++){

		document.getElementById('page' + i).style.display = 'none';

	 }

	document.getElementById('page' + id).style.display = 'block';
}


// -------------------- Contacts --------------

function visible( obj, v ) {
	obj.style.display = ( v ) ? 'block' : 'none';
}

function checkChars( str_length, max_chars ) {
	return max_chars - str_length;
}

function charsChecker( obj, alertObj, max_chars )
{
	obj.onblur = obj.onkeyup = function()
	{
		var n = checkChars( this.value.length, max_chars );

		if ( n < 0 ) {
			alertObj.innerHTML = 'Please remove ' + (-n) + ' chars from your text field.';
		}
		else {
			alertObj.innerHTML = n;
		}
	};

	obj.onblur();
}

function isValidEmail( $str )
{
	var $isValid = true;

	$str = $str + '';

	//
	if ($str.indexOf("@") == -1) {
		$isValid = false;
	}
	//
	var $array = new Array();
	$array = $str.split("@");
	//
	if ( $array.length != 2 )
	{
		$isValid = false;
		return $isValid;
	}

	if ($array[0] == "") {
		$isValid = false;
	}
	if ($array[1].indexOf(".") == -1) {
		$isValid = false;
	}
	//
	var $array2 = new Array();
	$array2 = $array[1].split(".");
	//
	if ($array2[0] == "") {
		$isValid = false;
	}
	if ($array2[1] == "") {
		$isValid = false;
	}
	//
	return $isValid;
}

function isValidZipCode( str )
{

	var isValid = true;
/*
	str = str + '';

	if ( str.substr(0,1) == '0' )
	{
		if ( isNaN( str.substr(1,4) ) ) {
			isValid = false;
		}
		else
		{
			if ( str.substr(1,4) == '0000' ) {
				isValid = false;
			}
		}
	}
	else
	{
		if ( isNaN( str ) ) {
			isValid = false;
		}
	}

	if ( str.length != 5 ) {
		isValid = false;
	}
*/
	return isValid;
}

function isValidPhone($str)
{


	var $isValid = true;

	$str = $str + '';
	/*
	var $prefix = $str.substr(0,2);

	if ( $prefix != "01" && $prefix != "02" && $prefix != "03" && $prefix != "04" && $prefix != "05" && $prefix != "08" && $prefix != "09") {
		$isValid = false;
	}
	*/
	if ($str.length == 0) {
		$isValid = false;
	}

	return $isValid;
}

function isValidMobile( $str )
{

	var $isValid = true;

	$str = $str + '';
	/*
	var $prefix = $str.substr(0,2);

	if ($prefix != "06") {
		$isValid = false;
	}
	*/
	if ($str.length == 0) {
		$isValid = false;
	}

	return $isValid;
}

function formatDate( str, separator )
{
	var _ = str;

	var _split = str.split( separator );

	var s_jj = new String( _split[0] );
	var s_mm = new String( _split[1] );
	var s_aaaa = new String( _split[2] );

	var jj = new Number( s_jj );
	var mm = new Number( s_mm );

	if ( jj < 10 ) {
		s_jj = '0' + jj;
	}

	if ( mm < 10 ) {
		s_mm = '0' + mm;
	}

	_ = s_jj + separator + s_mm + separator + s_aaaa;

	return _;
}

function isValidDate( str, separator )
{
	var $isValid = true;

	str = str + '';
	str = formatDate( str, separator );

	var _split = str.split( separator );

	if ( _split.length != 3 ) {
		$isValid = false;
	}
	else
	{
		if ( (_split[0].length == 2) && (_split[1].length == 2) && (_split[2].length == 4) )
		{
			if ( isNaN( new String(_split[0]) ) || isNaN( new String(_split[1]) ) || isNaN( new String(_split[2]) ) )
			{
				$isValid = false;
			}
			else
			{
				var c1 = new Number( new String(_split[0]) );
				var c2 = new Number( new String(_split[1]) );
				var c3 = new Number( new String(_split[2]) );

				if ( c1 > 31 || c2 > 12 ) {
					$isValid = false;
				}
				else
				{
					var _date = new Date();

					_date.setYear( c3 );
					_date.setMonth( c2 - 1 );
					_date.setDate( c1 );

					var test_jj = ( _date.getDate() < 10 ) ? '0' + _date.getDate() : _date.getDate();
					var test_mm = ( (_date.getMonth() + 1) < 10 ) ? '0' + (_date.getMonth() + 1) : (_date.getMonth() + 1);

					var test_date = test_jj + separator + test_mm + separator + _date.getFullYear();

					if ( test_date != str ) {
						$isValid = false;
					}
				}
			}
		}
		else
		{
			$isValid = false;
		}
	}

	return $isValid;
}

function checkForm( objs )
{

	for ( var i = 0; i < objs.length; i++ )
	{
		if ( objs[i].type == 'text' )
		{
			var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( (objs[i].elt.value.length < 1) || (objs[i].elt.value.length > objs[i]._max) )
			{
				if ( !optional )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
				else
				{
					if ( objs[i].elt.value.length > 0 )
					{
						if ( typeof( objs[i].callback ) != 'undefined' ) {
							objs[i].callback( objs[i] );
						}
						else {
							alert( objs[i].msg );
						}
						return false;
					}
				}
			}

			if ( typeof( objs[i]._min ) != 'undefined' )
			{
				if ( objs[i].elt.value.length < objs[i]._min )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
			}
		}
		else if ( objs[i].type == 'checkbox' )
		{
			var n = 0;

			for ( var ii = 0; ii < objs[i].elt.length; ii++ )
			{
				if ( objs[i].elt[ii].checked ) {
					n++;
				}
			}

			objs[i]._min = ( typeof( objs[i]._min ) == 'undefined' ) ? 0 : objs[i]._min;
			objs[i]._max = ( typeof( objs[i]._max ) == 'undefined' ) ? objs[i].elt.length : objs[i]._max;

			if ( (n < objs[i]._min) || (n > objs[i]._max) )
			{
				if ( typeof( objs[i].callback ) != 'undefined' ) {
					objs[i].callback( objs[i] );
				}
				else {
					alert( objs[i].msg );
				}

				return false;
			}
		}
		else if ( objs[i].type == 'mail' )
		{
			var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( !isValidEmail( objs[i].elt.value ) )
			{
				if ( !optional )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
				else
				{
					if ( objs[i].elt.value.length > 0 )
					{
						if ( typeof( objs[i].callback ) != 'undefined' ) {
							objs[i].callback( objs[i] );
						}
						else {
							alert( objs[i].msg );
						}

						return false;
					}
				}
			}
		}
		else if ( objs[i].type == 'zipcode' )
		{
			var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( !isValidZipCode( objs[i].elt.value ) )
			{
				if ( !optional )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
				else
				{
					if ( objs[i].elt.value.length > 0 )
					{
						if ( typeof( objs[i].callback ) != 'undefined' ) {
							objs[i].callback( objs[i] );
						}
						else {
							alert( objs[i].msg );
						}

						return false;
					}
				}
			}
		}
		else if ( (objs[i].type == 'phone') || (objs[i].type == 'mobile') )
		{
			var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( !isValidPhone( objs[i].elt.value ) && !isValidMobile( objs[i].elt.value ) )
			{
				if ( !optional )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
				else
				{
					if ( objs[i].elt.value.length > 0 )
					{
						if ( typeof( objs[i].callback ) != 'undefined' ) {
							objs[i].callback( objs[i] );
						}
						else {
							alert( objs[i].msg );
						}

						return false;
					}
				}
			}
		}
		else if ( objs[i].type == 'date' )
		{
			var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( !isValidDate( objs[i].elt.value, '/' ) )
			{
				if ( !optional )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
				else
				{
					if ( objs[i].elt.value.length > 0 )
					{
						if ( typeof( objs[i].callback ) != 'undefined' ) {
							objs[i].callback( objs[i] );
						}
						else {
							alert( objs[i].msg );
						}

						return false;
					}
				}
			}
		}
		else if ( objs[i].type == 'noZero' )
		{
			var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( !optional )
			{
				if ( objs[i].elt.value == '0' )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
			}
		}else if ( objs[i].type == 'pays' )
		{
			var optional = false;
			
			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}
			
			if ( objs[i].elt.value == 0 )
			{ 
				if ( !optional )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}
					
					return false;
				}
			}
		}
	}

	return true;
}



function checkForm2( objs )
{
	for ( var i = 0; i < objs.length; i++ )
	{
		if ( objs[i].type == 'text' )
		{
			var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( (objs[i].elt.value.length < 1) || (objs[i].elt.value.length > objs[i]._max) )
			{
				if ( !optional )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
				else
				{
					if ( objs[i].elt.value.length > 0 )
					{
						if ( typeof( objs[i].callback ) != 'undefined' ) {
							objs[i].callback( objs[i] );
						}
						else {
							alert( objs[i].msg );
						}

						return false;
					}
				}
			}

			if ( typeof( objs[i]._min ) != 'undefined' )
			{
				if ( objs[i].elt.value.length < objs[i]._min )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
			}
		}
		else if ( objs[i].type == 'checkbox' )
		{
			var n = 0;

			for ( var ii = 0; ii < objs[i].elt.length; ii++ )
			{
				if ( objs[i].elt[ii].checked ) {
					n++;
				}
			}

			objs[i]._min = ( typeof( objs[i]._min ) == 'undefined' ) ? 0 : objs[i]._min;
			objs[i]._max = ( typeof( objs[i]._max ) == 'undefined' ) ? objs[i].elt.length : objs[i]._max;

			if ( (n < objs[i]._min) || (n > objs[i]._max) )
			{
				if ( typeof( objs[i].callback ) != 'undefined' ) {
					objs[i].callback( objs[i] );
				}
				else {
					alert( objs[i].msg );
				}

				return false;
			}
		}
		else if ( objs[i].type == 'mail' )
		{
			var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( !isValidEmail( objs[i].elt.value ) )
			{
				if ( !optional )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
				else
				{
					if ( objs[i].elt.value.length > 0 )
					{
						if ( typeof( objs[i].callback ) != 'undefined' ) {
							objs[i].callback( objs[i] );
						}
						else {
							alert( objs[i].msg );
						}

						return false;
					}
				}
			}
		}

		else if ( objs[i].type == 'zipcode' )
		{



			if(objs[i].elt.value == '' || objs[i].elt.value == 'undefined '){
				return false;
			}


			/*var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( !isValidZipCode( objs[i].elt.value ) )
			{
				if ( !optional )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
				else
				{
					if ( objs[i].elt.value.length > 0 )
					{
						if ( typeof( objs[i].callback ) != 'undefined' ) {
							objs[i].callback( objs[i] );
						}
						else {
							alert( objs[i].msg );
						}

						return false;
					}
				}
			}
			*/
		}

		else if ( (objs[i].type == 'phone') || (objs[i].type == 'mobile') )
		{
			var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( !isValidPhone( objs[i].elt.value ) && !isValidMobile( objs[i].elt.value ) )
			{
				if ( !optional )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
				else
				{
					if ( objs[i].elt.value.length > 0 )
					{
						if ( typeof( objs[i].callback ) != 'undefined' ) {
							objs[i].callback( objs[i] );
						}
						else {
							alert( objs[i].msg );
						}

						return false;
					}
				}
			}
		}
		else if ( objs[i].type == 'date' )
		{
			var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( !isValidDate( objs[i].elt.value, '/' ) )
			{
				if ( !optional )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
				else
				{
					if ( objs[i].elt.value.length > 0 )
					{
						if ( typeof( objs[i].callback ) != 'undefined' ) {
							objs[i].callback( objs[i] );
						}
						else {
							alert( objs[i].msg );
						}

						return false;
					}
				}
			}
		}
		else if ( objs[i].type == 'noZero' )
		{
			var optional = false;

			if ( typeof( objs[i].optional ) != 'undefined' ) {
				optional = objs[i].optional;
			}

			if ( !optional )
			{
				if ( objs[i].elt.value == '0' )
				{
					if ( typeof( objs[i].callback ) != 'undefined' ) {
						objs[i].callback( objs[i] );
					}
					else {
						alert( objs[i].msg );
					}

					return false;
				}
			}
		}
	}

	return true;
}



var intV = 0;

function hideMsg( obj )
{
	clearInterval( intV );

	visible( obj, false );
}

function affichMsg( container, box, msg )
{
	visible( container, true );

	var winY = window.pageYOffset || document.body.scrollTop || document.documentElement.scrollTop;

	container.style.top = winY + 'px';
	box.innerHTML = msg;

	hideMsg_str = 'hideMsg(' + container.id + ')';

	intV = setInterval( hideMsg_str, 3000 );
}

function restoreClass( id )
{
	window.document.getElementById('erreur').innerHTML = '';

	clearInterval( intV );
	window.document.getElementById( id ).className = 'textField';
}

function highLighted( obj )
{
	window.document.getElementById('erreur').innerHTML = obj.msg;

	//obj.elt.className = 'hightLForm';
	//intV = setInterval( ('restoreClass(\'' + obj.elt.id + '\')'), 3000 );
}

function similarStr( str1, str2 ) {
	//alert('str1:' + str1 + "str2:"+ str2);
	return (str1 === str2);
}

function checkEmailSim()
{
	var v = similarStr( window.document.getElementById('email').value, window.document.getElementById('confemail').value );

	if ( !v ) {
		highLighted( {elt:window.document.getElementById('confemail'),msg:'Confirme su e-mail.'} );
	}

	return v;
}

function checkMPSim()
{
	var v = similarStr( window.document.getElementById('mp').value, window.document.getElementById('confmp').value );

	if ( !v ) {
		highLighted( {elt:window.document.getElementById('confmp'),msg:'Confirme su e-mail.'} );
	}

	return v;
}

/******************************************************** POPUPS ******************************************************/
function getBrowserCodeName()
{
	var name = null;

	if ( document.getElementById && !document.all )
	{
		name = 'NS6';
	}
	else if ( document.all )
	{
		name = 'IE';
	}
	else if ( navigator.appName == 'Netscape' && navigator.appVersion.charAt( 0 ) == '4' )
	{
		name = 'NS';
	}
	else if ( navigator.userAgent.indexOf( 'Mac' ) != -1 )
	{
		name = 'MAC';
	}

	return name;
}


function detectIE6(){
	var IE6 = false

	var strChUserAgent = navigator.userAgent;
	var intSplitStart = strChUserAgent.indexOf("(",0);
	var intSplitEnd = strChUserAgent.indexOf(")",0);
	var strChMid = strChUserAgent.substring(intSplitStart, intSplitEnd);

	if(strChMid.indexOf("MSIE 6") != -1) IE6 = true;

	return IE6;
}



function getScrollY() {
  scrOfY = 0;
  if( typeof( window.pageYOffset ) == 'number' ) {
    //Netscape compliant
    scrOfY = window.pageYOffset;
  } else if( document.body && ( document.body.scrollTop ) ) {
    //DOM compliant
    scrOfY = document.body.scrollTop;
  } else if( document.documentElement && ( document.documentElement.scrollTop ) ) {
    //IE6 standards compliant mode
    scrOfY = document.documentElement.scrollTop;
  }
  return scrOfY;
}


function affichPopup( nom ){

	/*Sous IE6 on masque les listes de formulaires*/
	if ( detectIE6() ){

		tags = document.getElementsByTagName( "select" );

		for( i=0; i<tags.length; i++ ){
				tags.item( i ).style.visibility = "hidden";
			}

	}

	maskPage();
	window.document.getElementById( 'mask_page' ).style.display = "block";


	window.document.getElementById( nom ).style.display = "block";

}

function closePopup( nom ){

	/*Sous IE6 on masque les listes de formulaires*/
	if ( detectIE6() ){

		tags = document.getElementsByTagName( "select" );

		for( i=0; i<tags.length; i++ ){
				tags.item( i ).style.visibility = "visible";
			}

	}

	window.document.getElementById( 'mask_page' ).style.display = "none";

	window.document.getElementById( nom ).style.display = "none";

}


//Init des positions du masque
function maskPage()
{
	var obj = document.getElementById('mask_page').style;

	//var winY = document.documentElement.scrollTop;
	var winY = getScrollY();
	var winL = 1024;
	//var winH = document.documentElement.clientHeight;
	var winH = "";
	if ( window.innerHeight ) winH = window.innerHeight;
	if ( document.documentElement ) winH = document.documentElement.clientHeight;
	if ( document.body ) winH = document.body.clientHeight;

	if ( getBrowserCodeName() == 'IE' )
	{
		obj.width = winL;
		obj.height = winH + winY;
	}
	else if ( getBrowserCodeName() == 'NS6' || getBrowserCodeName() == 'NS' )
	{
		obj.width = winL + 'px';
		obj.height = ( winH + winY ) + 'px';
	}
}

function affichPopup( nom ){

	/*Sous IE6 on masque les listes de formulaires*/
	if ( detectIE6() ){

		tags = document.getElementsByTagName( "select" );

		for( i=0; i<tags.length; i++ ){
				tags.item( i ).style.visibility = "hidden";
			}

	}

	maskPage();
	window.document.getElementById( 'mask_page' ).style.display = "block";


	window.document.getElementById( nom ).style.display = "block";

}

function closePopup( nom ){

	/*Sous IE6 on masque les listes de formulaires*/
	if ( detectIE6() ){

		tags = document.getElementsByTagName( "select" );

		for( i=0; i<tags.length; i++ ){
				tags.item( i ).style.visibility = "visible";
			}

	}

	window.document.getElementById( 'mask_page' ).style.display = "none";

	window.document.getElementById( nom ).style.display = "none";

}


//Init des positions du masque
function maskPage()
{
	var obj = document.getElementById('mask_page').style;

	//var winY = document.documentElement.scrollTop;
	var winY = getScrollY();
	var winL = 1024;
	//var winH = document.documentElement.clientHeight;
	var winH = "";
	if ( window.innerHeight ) winH = window.innerHeight;
	if ( document.documentElement ) winH = document.documentElement.clientHeight;
	if ( document.body ) winH = document.body.clientHeight;

	if ( getBrowserCodeName() == 'IE' )
	{
		obj.width = winL;
		obj.height = winH + winY;
	}
	else if ( getBrowserCodeName() == 'NS6' || getBrowserCodeName() == 'NS' )
	{
		obj.width = winL + 'px';
		obj.height = ( winH + winY ) + 'px';
	}
}

