From 515ec353d79da27aa761d85532803dd42ff1a0e1 Mon Sep 17 00:00:00 2001
From: Simon Leblanc <contact@leblanc-simon.eu>
Date: Sun, 29 May 2011 03:39:36 +0200
Subject: [PATCH] Allow all text in hour

---
 choix_date.php | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/choix_date.php b/choix_date.php
index 907e8a04..8b6b6ac9 100644
--- a/choix_date.php
+++ b/choix_date.php
@@ -85,7 +85,8 @@ if (!issetAndNoEmpty('nom', $_SESSION) && !issetAndNoEmpty('adresse', $_SESSION)
               $choixdate.=",";
               $choixdate .= $_SESSION["totalchoixjour"][$i];
               $choixdate.="@";
-              $choixdate .= $_SESSION["horaires$i"][$j];
+              // On remplace la virgule et l'arobase pour ne pas avoir de problème par la suite
+              $choixdate .= str_replace(array(',', '@'), array('&#44;', '&#64;'), $_SESSION["horaires$i"][$j]);
             }
           }
         }
@@ -461,8 +462,8 @@ if (!issetAndNoEmpty('nom', $_SESSION) && !issetAndNoEmpty('adresse', $_SESSION)
           } elseif ($_POST["horaires$i"][$j]=="") { //Si la case est vide
             unset($_SESSION["horaires$i"][$j]);
           } else { //pour tout autre format, message d'erreur
-            $errheure[$i][$j]=true;
-            $erreur=true;
+            //$errheure[$i][$j]=true;
+            //$erreur=true;
             $_SESSION["horaires$i"][$j] = $_POST["horaires$i"][$j];
           }
         }
-- 
GitLab