function Submit_commandes(){

 /* var image = V('image');
  var extension1 = image.substr(image.length-4,4);*/
  
   if(O('id_produit')) {
     if  (IsEmpty(V('id_produit'))) return Msg_Erreur('Veuillez svp renseigner <b>le produit</b> Concerné.', 'id_produit', 'commandes');
   }	
  if  (IsEmpty(V('nom'))) return Msg_Erreur('Veuillez svp renseigner <b>Votre Nom</b>.', 'nom', 'commandes');
  if  (IsEmpty(V('prenoms'))) return Msg_Erreur('Veuillez svp renseigner <b>Votre prenom</b>.', 'prenoms', 'commandes');
  if  (IsEmpty(V('tel'))) return Msg_Erreur('Veuillez indiquer votre Numéro de téléphone.', 'tel', 'commandes');
  else{
	  if  (!IsNumeric(V('tel'))) return Msg_Erreur('Veuillez S.V.P. saisir un numéro de téléphone valide ( Numérique ).', 'tel', 'commandes');
	  }
  if  (IsEmpty(V('le_email'))) return Msg_Erreur('Veuillez indiquer votre adresse email.', 'le_email', 'commandes');
			else {
				 if(!IsMail(V('le_email'))) return Msg_Erreur('L\'adresse email spécifiée n\'est pas valide.', 'le_email', 'commandes');
			}
  if  (IsEmpty(V('id_pays'))) return Msg_Erreur('Veuillez svp renseigner votre<b>Pays de résidence</b>.', 'id_pays', 'commandes');
  //if  (IsEmpty(V('date_publication'))) return Msg_Erreur('Veuillez svp renseigner la<b>Date de publication</b> de la Demande.', 'date_publication', 'demande_prieres');
  if  (IsEmpty(V('Code_Securite_1'))) return Msg_Erreur('Veuillez S.V.P. saisir le Code de Sécurité affiché.', 'Code_Securite_1', 'commandes');
  else {
	  if  (!IsNumeric(V('Code_Securite_1'))) return Msg_Erreur('Veuillez S.V.P. saisir un Code de Sécurité valide ( Numérique ).', 'Code_Securite_1', 'commandes');
	  else {
		 //alert(V('Code_Securite_1') + '/' + V('Code_M_1'));
		  if (V('Code_M_1') != V('Code_Securite_1')) return Msg_Erreur('Le Code de Sécurité entré ne correspond pas au code généré.', 'Code_Securite_1', 'commandes');
	  }	
  }
  O('img_ajax_commandes').style.display = 'block';
  O('commandes').target = 'upload_target';
  //O('upload_target').onload=uploadDone;
  
}


function Submit_villes(){

 /* var image = V('image');
  var extension1 = image.substr(image.length-4,4);*/
  
   if(O('id_district')) {
     if  (IsEmpty(V('id_district'))) return Msg_Erreur('Veuillez svp renseigner <b>le District</b> Concerné.', 'id_district', 'villes');
   }	
  if  (IsEmpty(V('libelle'))) return Msg_Erreur('Veuillez svp renseigner <b>le libellé</b>.', 'libelle', 'villes');

  if  (IsEmpty(V('Code_Securite_1'))) return Msg_Erreur('Veuillez S.V.P. saisir le Code de Sécurité affiché.', 'Code_Securite_1', 'villes');
  else {
	  if  (!IsNumeric(V('Code_Securite_1'))) return Msg_Erreur('Veuillez S.V.P. saisir un Code de Sécurité valide ( Numérique ).', 'Code_Securite_1', 'villes');
	  else {
		 //alert(V('Code_Securite_1') + '/' + V('Code_M_1'));
		  if (V('Code_M_1') != V('Code_Securite_1')) return Msg_Erreur('Le Code de Sécurité entré ne correspond pas au code généré.', 'Code_Securite_1', 'villes');
	  }	
  }
  O('img_ajax_villes').style.display = 'block';
  O('villes').target = 'upload_target';
  //O('upload_target').onload=uploadDone;
}

function Submit_prieres(){

  if(O('image')) {
    var image = V('image');
    var extension1 = image.substr(image.length-4,4);
  }
  
  if  (IsEmpty(V('libelle'))) return Msg_Erreur('Veuillez svp renseigner le<b>Titre</b> de la Demande.', 'libelle', 'demande_prieres');
  if  (IsEmpty(V('description'))) return Msg_Erreur('Veuillez svp Saisir <b>Votre Message</b>.', 'description', 'demande_prieres');
  
  if(O('image')) {
  //if  (IsEmpty(V('image')) && IsEmpty(V('anc_image'))) return Msg_Erreur('Veuillez svp renseigner le champ <b>Image</b>.', 'image', 'demande_prieres');
  //else {
      if(V('image')) {
	    if  (extension1.toUpperCase() != '.GIF' && extension1.toUpperCase() != '.JPG' && extension1.toUpperCase() != 'JPEG') return Msg_Erreur('Seuls les formats <b>GIF</b> et <b>JPEG</b> sont autorisés pour les images.', 'image', 'demande_prieres');
	  }
  //}
  }
  if  (IsEmpty(V('Code_Securite_1'))) return Msg_Erreur('Veuillez S.V.P. saisir le Code de Sécurité affiché.', 'Code_Securite_1', 'demande_prieres');
  else {
	  if  (!IsNumeric(V('Code_Securite_1'))) return Msg_Erreur('Veuillez S.V.P. saisir un Code de Sécurité valide ( Numérique ).', 'Code_Securite_1', 'demande_prieres');
	  else {
		 //alert(V('Code_Securite_1') + '/' + V('Code_M_1'));
		  if (V('Code_M_1') != V('Code_Securite_1')) return Msg_Erreur('Le Code de Sécurité entré ne correspond pas au code généré.', 'Code_Securite_1', 'demande_prieres');
	  }	
  }
  O('img_ajax_demande_prieres').style.display = 'block';
  O('demande_prieres').target = 'upload_target';
  //O('upload_target').onload=uploadDone;
  
}
