diff --git a/core/class/layout.class.php b/core/class/layout.class.php index 35b29c9b..a696a4e8 100644 --- a/core/class/layout.class.php +++ b/core/class/layout.class.php @@ -280,7 +280,8 @@ class layout extends common // Affichage de motorisé par $items .= 'getData(['theme', 'footer', 'displayCopyright']) === false ? 'class="displayNone"' : ''; - $items .= '>'.sprintf('%s ', helper::translate('Motorisé par')) . ''; + $label = empty($this->getData(['locale', 'poweredPageLabel'])) ? 'Motorisé par' : $this->getData(['locale', 'poweredPageLabel']); + $items .= '> ' . $label . ' '; // Toujours afficher le nom du CMS $items .= ''; $items .= 'ZwiiCMS'; diff --git a/core/include/update.inc.php b/core/include/update.inc.php index 2a4276ed..c6d84270 100644 --- a/core/include/update.inc.php +++ b/core/include/update.inc.php @@ -956,12 +956,30 @@ if ($this->getData(['core', 'dataVersion']) < 12308) { 'es' => 'Español', ]; foreach ($l as $key => $value) { - if (is_dir(self::DATA_DIR . $key )) { + if (is_dir(self::DATA_DIR . $key)) { touch(self::DATA_DIR . $key . '/.default'); break; } } - + // Mise à jour $this->setData(['core', 'dataVersion', 12308]); +} + +// Version 12.3.09 +if ($this->getData(['core', 'dataVersion']) < 12309) { + + // Mettre à jour les locales + foreach (self::$languages as $key => $value) { + // tableau des langues installées + if (is_dir(self::DATA_DIR . $key)) { + $d = json_decode(file_get_contents(self::DATA_DIR . $key . '/locale.json'), true); + $d = array_merge($d['locale'],['poweredPageLabel' => 'Motorisé par']); + $t ['locale'] = $d; + file_put_contents(self::DATA_DIR . $key . '/locale.json', json_encode($t)); + } + } + + // Mise à jour + $this->setData(['core', 'dataVersion', 12309]); } \ No newline at end of file diff --git a/core/module/install/ressource/defaultdata.php b/core/module/install/ressource/defaultdata.php index 7d9ece2e..6cebf385 100644 --- a/core/module/install/ressource/defaultdata.php +++ b/core/module/install/ressource/defaultdata.php @@ -58,6 +58,7 @@ class init extends common 'page404' => 'none', 'legalPageId' => 'none', 'searchPageId' => 'none', + 'poweredPageLabel'=> 'Motorisé par', 'searchPageLabel' => 'Rechercher', 'sitemapPageLabel' => 'Plan du site', 'legalPageLabel' => 'Mentions légales', @@ -347,6 +348,7 @@ class init extends common 'searchPageId' => 'none', 'searchPageLabel' => 'none', 'sitemapPageLabel' => 'none', + 'poweredPageLabel'=> 'Powered by', 'legalPageLabel' => 'legals', 'metaDescription' => 'Zwii is a database-free CMS that makes it easy to create and manage a website without any programming knowledge.', 'title' => 'Your site in a few clicks!', @@ -1024,6 +1026,7 @@ class init extends common 'page404' => 'none', 'legalPageId' => 'none', 'searchPageId' => 'none', + 'poweredPageLabel'=> 'Motorisé par', 'searchPageLabel' => 'Rechercher', 'sitemapPageLabel' => 'Plan du site', 'legalPageLabel' => 'Mentions légales', diff --git a/core/module/translate/translate.php b/core/module/translate/translate.php index 60783e3a..56b22443 100644 --- a/core/module/translate/translate.php +++ b/core/module/translate/translate.php @@ -390,6 +390,7 @@ class translate extends common 'page302' => $this->getInput('localePage302'), 'legalPageId' => $this->getInput('localeLegalPageId'), 'searchPageId' => $this->getInput('localeSearchPageId'), + 'poweredPageLabel' => empty($this->getInput('localePoweredPageLabel', helper::FILTER_STRING_SHORT)) ? 'Motorisé par' : $this->getInput('localePoweredPageLabel', helper::FILTER_STRING_SHORT), 'searchPageLabel' => empty($this->getInput('localeSearchPageLabel', helper::FILTER_STRING_SHORT)) ? 'Rechercher' : $this->getInput('localeSearchPageLabel', helper::FILTER_STRING_SHORT), 'legalPageLabel' => empty($this->getInput('localeLegalPageLabel', helper::FILTER_STRING_SHORT)) ? 'Mentions légales' : $this->getInput('localeLegalPageLabel', helper::FILTER_STRING_SHORT), 'sitemapPageLabel' => empty($this->getInput('localeSitemapPageLabel', helper::FILTER_STRING_SHORT)) ? 'Plan du site' : $this->getInput('localeSitemapPageLabel', helper::FILTER_STRING_SHORT), diff --git a/core/module/translate/view/locale/locale.php b/core/module/translate/view/locale/locale.php index 87b187c6..573b9fe4 100644 --- a/core/module/translate/view/locale/locale.php +++ b/core/module/translate/view/locale/locale.php @@ -113,14 +113,21 @@ -->
-
+
+ 'Motorisé par', + 'placeholder' => 'Motorisé par', + 'value' => $module::$locales[$this->getUrl(2)]['locale']['poweredPageLabel'] + ]); ?> +
+
'Mentions légales', 'placeholder' => 'Mentions légales', 'value' => $module::$locales[$this->getUrl(2)]['locale']['legalPageLabel'] ]); ?>
-
+
'Rechercher', 'placeholder' => 'Rechercher', @@ -129,14 +136,14 @@
-
+
'Plan du site', 'placeholder' => 'Plan du site', 'value' => $module::$locales[$this->getUrl(2)]['locale']['sitemapPageLabel'], ]); ?>
-
+
'Cookies', 'value' => $module::$locales[$this->getUrl(2)]['locale']['cookies']['cookiesFooterText'],