# HG changeset patch # User Yves-Marie Haussonne <1218002+ymph@users.noreply.github.com> # Date 1385414888 -3600 # Node ID c294569b0725b6d5236f25b40a674b834bf501db # Parent 2ac0430550ffb31c055505c2bb2c1b5ff7d039d9 make title compulsory diff -r 2ac0430550ff -r c294569b0725 web/event_form.php --- a/web/event_form.php Mon Nov 25 19:18:23 2013 +0100 +++ b/web/event_form.php Mon Nov 25 22:28:08 2013 +0100 @@ -81,17 +81,17 @@
+ + +
_("title_help"); ?>
+ +
+
_("hashtag_help"); ?>
- - -
_("title_help"); ?>
- -
-
_("abstract_help"); ?>
diff -r 2ac0430550ff -r c294569b0725 web/event_list.php --- a/web/event_list.php Mon Nov 25 19:18:23 2013 +0100 +++ b/web/event_list.php Mon Nov 25 22:28:08 2013 +0100 @@ -102,7 +102,7 @@ if (stripos($ind_file, '.') !== 0) { $token = base64_encode( $iv . - openssl_encrypt( + @openssl_encrypt( $iv.$ind_file, 'aes256', hash('sha256', SECRET, true), diff -r 2ac0430550ff -r c294569b0725 web/event_process.php --- a/web/event_process.php Mon Nov 25 19:18:23 2013 +0100 +++ b/web/event_process.php Mon Nov 25 22:28:08 2013 +0100 @@ -133,8 +133,12 @@ } else { + $config_values = array_merge($_POST); - $config_values = array_merge($_POST); + if(!isset($config_values['title']) || empty($config_values['title'])) { + print "

".$translate->_("Event_error_empty_title")."

"; + exit; + } foreach ($_FILES as $key => $value) { $config_values[$key] = "images/".basename($value['name']); diff -r 2ac0430550ff -r c294569b0725 web/traductions/en.php --- a/web/traductions/en.php Mon Nov 25 19:18:23 2013 +0100 +++ b/web/traductions/en.php Mon Nov 25 22:28:08 2013 +0100 @@ -186,7 +186,7 @@ "archive_description" => "archive description", "hashtag_help" => "Hashtag used by Polemictweet to display the realtime timeline (format: #hashtag).", - "title_help" => "Title of the event as displayed in the browser title bar, under the video player during the live and on the left of the video player after the event.", + "title_help" => "Title of the event as displayed in the browser title bar, under the video player during the live and on the left of the video player after the event. This field is compulsory.", "abstract_help" => "A short description of the event displayed on the home page's slider. Can contain HTML code.", "description_help" => "The program displayed under the live player and on the left of the replay player. Can contain HTML code.", "link_help" => "Program URL, displayed when clicking on “Programme” in the page header.", @@ -201,6 +201,7 @@ "archive_title_help" => "Title of the archive.", "archive_description_help" => "Description of the archive.", + "Event_error_empty_title" => "Error, the event title is empty.", "Event_recorded_message" => "Your event as been correctly recorded. Contact us to publish it on Polemictweet.", "Event_confirm_delete_archive" => "Are your sure to delete the event configuration ?", diff -r 2ac0430550ff -r c294569b0725 web/traductions/fr.php --- a/web/traductions/fr.php Mon Nov 25 19:18:23 2013 +0100 +++ b/web/traductions/fr.php Mon Nov 25 22:28:08 2013 +0100 @@ -179,7 +179,7 @@ "archive_description" => "description archive", "hashtag_help" => "Le mot-dièse que PolemicTweet utilisera pour afficher la frise technologique en temps réel (format : #hashtag).", - "title_help" => "Le titre de l’événement tel qu’il s’affiche dans la barre de titre du navigateur, sous le player vidéo pendant le temps réel et à gauche du player vidéo en temps différé.", + "title_help" => "Le titre de l’événement tel qu’il s’affiche dans la barre de titre du navigateur, sous le player vidéo pendant le temps réel et à gauche du player vidéo en temps différé. Ce champ est obligatoire.", "abstract_help" => "Une description courte de l’événement telle qu’elle apparaît sur le carrousel de la page d’accueil. Peut contenir du code HTML.", "description_help" => "Le programme tel qu’il s’affiche en dessous du player live et à gauche du player replay. Peut contenir du code HTML.", "link_help" => "URL du programme, qui s’affiche lorsqu’on clique sur “Programme” dans l’entête de la page.", @@ -194,6 +194,7 @@ "archive_title_help" => "Titre de l'archive dans la liste des événements passés.", "archive_description_help" => "Description de l'archive dans la liste des événements passés.", + "Event_error_empty_title" => "Erreur, le titre de l'évènement est vide.", "Event_recorded_message" => "Votre évènement a été correctement enregistré. Contactez nous pour le publier sur Polemictweet.", "Event_confirm_delete_archive" => "Êtes-vous sur de vouloir effacer cette configuration d'évènement ?", diff -r 2ac0430550ff -r c294569b0725 web/traductions/ja.php --- a/web/traductions/ja.php Mon Nov 25 19:18:23 2013 +0100 +++ b/web/traductions/ja.php Mon Nov 25 22:28:08 2013 +0100 @@ -177,7 +177,7 @@ "archive_description" => "archive description", "hashtag_help" => "Hashtag used by Polemictweet to display the realtime timeline (format: #hashtag).", - "title_help" => "Title of the event as displayed in the browser title bar, under the video player during the live and on the left of the video player after the event.", + "title_help" => "Title of the event as displayed in the browser title bar, under the video player during the live and on the left of the video player after the event. This field is compulsory.", "abstract_help" => "A short description of the event displayed on the home page's slider. Can contain HTML code.", "description_help" => "The program displayed under the live player and on the left of the replay player. Can contain HTML code.", "link_help" => "Program URL, displayed when clicking on “Programme” in the page header.", @@ -192,6 +192,7 @@ "archive_title_help" => "Title of the archive.", "archive_description_help" => "Description of the archive.", + "Event_error_empty_title" => "Error, the event title is empty.", "Event_recorded_message" => "Your event as been correctly recorded. Contact us to publish it on Polemictweet.", "Event_confirm_delete_archive" => "Are your sure to delete the event configuration ?",