diff --git a/module/gallery/changes.md b/module/gallery/changes.md index a4433589..bd169e28 100644 --- a/module/gallery/changes.md +++ b/module/gallery/changes.md @@ -1,2 +1,4 @@ +# Version 3.61 + - Corrige le retour de $success en lecture écriture de fichier # Version 3.6 - Appel de la feuille de style si présente \ No newline at end of file diff --git a/module/gallery/gallery.php b/module/gallery/gallery.php index 2385d590..5c269a0f 100644 --- a/module/gallery/gallery.php +++ b/module/gallery/gallery.php @@ -17,7 +17,7 @@ class gallery extends common { - const VERSION = '3.6'; + const VERSION = '3.61'; const REALNAME = 'Galerie'; const DATADIRECTORY = self::DATA_DIR . 'gallery/'; @@ -843,12 +843,12 @@ class gallery extends common { $content = str_replace('#legendHeight#',$this->getinput('galleryThemeLegendHeight'),$content ); $content = str_replace('#legendTextColor#',$this->getinput('galleryThemeLegendTextColor'),$content ); $content = str_replace('#legendBgColor#',$this->getinput('galleryThemeLegendBgColor'),$content ); - $success = file_put_contents(self::DATADIRECTORY . $this->getUrl(0) . '/theme.css', $content . $themeCss); + $success = is_int(file_put_contents(self::DATADIRECTORY . $this->getUrl(0) . '/theme.css', $content . $themeCss)); // Valeurs en sortie $this->addOutput([ 'redirect' => helper::baseUrl() . $this->getUrl() . '/theme', - 'notification' => $success !== FALSE ? 'Modifications enregistrées' : 'Modifications non enregistrées !', - 'state' => $success !== FALSE + 'notification' => $success ? 'Modifications enregistrées' : 'Modifications non enregistrées !', + 'state' => $success ]); } // Valeurs en sortie diff --git a/module/news/changes.md b/module/news/changes.md index 241fbe16..2fac3f2e 100644 --- a/module/news/changes.md +++ b/module/news/changes.md @@ -1,3 +1,5 @@ +# Version 4.23 + - Corrige le retour de $success en lecture écriture de fichier # Version 4.22 - Initialisation du module # Version 4.21 diff --git a/module/news/news.php b/module/news/news.php index da746cfb..58c28946 100644 --- a/module/news/news.php +++ b/module/news/news.php @@ -16,7 +16,7 @@ class news extends common { - const VERSION = '4.22'; + const VERSION = '4.23'; const REALNAME = 'News'; const DATADIRECTORY = self::DATA_DIR . 'news/'; @@ -249,7 +249,7 @@ class news extends common mkdir(self::DATADIRECTORY . $this->getUrl(0) . '/theme.css', 0755, true); } - $success = file_put_contents(self::DATADIRECTORY . $this->getUrl(0) . '/theme.css', $style); + $success = is_int(file_put_contents(self::DATADIRECTORY . $this->getUrl(0) . '/theme.css', $style)); // Fin feuille de style diff --git a/module/search/changes.md b/module/search/changes.md index 9f11a065..989c0cc7 100644 --- a/module/search/changes.md +++ b/module/search/changes.md @@ -1,3 +1,5 @@ +# Version 2.71 + - Corrige le retour de $success en lecture écriture de fichier # Version 2.7 - Traduction - Suppression du cadre de présentation des résultats diff --git a/module/search/search.php b/module/search/search.php index 659d6662..904d0312 100644 --- a/module/search/search.php +++ b/module/search/search.php @@ -20,7 +20,7 @@ class search extends common { - const VERSION = '2.7'; + const VERSION = '2.71'; const REALNAME = 'Recherche'; const DATADIRECTORY = self::DATA_DIR . 'search/'; @@ -125,7 +125,7 @@ class search extends common // Générer la feuille de CSS $style = '.keywordColor {background:' . $this->getInput('searchKeywordColor') . ';}'; - $success = file_put_contents(self::DATADIRECTORY . $this->getUrl(0) . '/theme.css', $style); + $success = is_int(file_put_contents(self::DATADIRECTORY . $this->getUrl(0) . '/theme.css', $style)); // Fin feuille de style // Soumission du formulaire @@ -145,8 +145,8 @@ class search extends common // Valeurs en sortie, affichage du formulaire $this->addOutput([ 'redirect' => helper::baseUrl() . $this->getUrl(), - 'notification' => $success !== FALSE ? 'Modifications enregistrées' : 'Modifications non enregistrées !', - 'state' => $success !== FALSE + 'notification' => $success ? 'Modifications enregistrées' : 'Modifications non enregistrées !', + 'state' => $success ]); } // Valeurs en sortie, affichage du formulaire