diff --git a/core/core.php b/core/core.php
index 890c7368..4a98bdd2 100644
--- a/core/core.php
+++ b/core/core.php
@@ -1844,6 +1844,7 @@ class common {
$notificationClass = 'notificationSuccess';
}
if(common::$inputNotices) {
+ var_dump ( common::$inputNotices );
$notification = 'Impossible de soumettre le formulaire, car il contient des erreurs';
$notificationClass = 'notificationError';
}
diff --git a/core/include/update.inc.php b/core/include/update.inc.php
index 6cfd3502..dd14a012 100644
--- a/core/include/update.inc.php
+++ b/core/include/update.inc.php
@@ -674,7 +674,13 @@ if ($this->getData(['core', 'dataVersion']) < 11100) {
// Version 11.2.00
if ($this->getData(['core', 'dataVersion']) < 11200) {
- // Déplacer la valeur captcha
+
+ // Mise àjour des données de config
$this->setData(['config', 'connect', 'captchaStrong', $this->getData(['config', 'captchaStrong'])]);
+ $this->deleteData(['config', 'captchaStrong']);
+ $this->setData(['config', 'connect', 'autoDisconnect', $this->getData(['config', 'autoDisconnect'])]);
+ $this->deleteData(['config', 'autoDisconnect']);
+
+ // Mise à jour
$this->setData(['core', 'dataVersion', 11200]);
}
diff --git a/core/module/config/config.php b/core/module/config/config.php
index 8b813ddf..3742ccba 100644
--- a/core/module/config/config.php
+++ b/core/module/config/config.php
@@ -443,6 +443,12 @@ class config extends common {
'cookieConsent' => $this->getInput('configCookieConsent', helper::FILTER_BOOLEAN),
'favicon' => $this->getInput('configFavicon'),
'faviconDark' => $this->getInput('configFaviconDark'),
+ 'timezone' => $this->getInput('configTimezone', helper::FILTER_STRING_SHORT),
+ 'autoUpdate' => $this->getInput('configAutoUpdate', helper::FILTER_BOOLEAN),
+ 'autoUpdateHtaccess' => $this->getInput('configAutoUpdateHtaccess', helper::FILTER_BOOLEAN),
+ 'proxyType' => $this->getInput('configProxyType'),
+ 'proxyUrl' => $this->getInput('configProxyUrl'),
+ 'proxyPort' => $this->getInput('configProxyPort',helper::FILTER_INT),
'social' => [
'facebookId' => $this->getInput('configSocialFacebookId'),
'linkedinId' => $this->getInput('configSocialLinkedinId'),
@@ -453,14 +459,6 @@ class config extends common {
'youtubeUserId' => $this->getInput('configSocialYoutubeUserId'),
'githubId' => $this->getInput('configSocialGithubId')
],
- 'timezone' => $this->getInput('configTimezone', helper::FILTER_STRING_SHORT, true),
- 'autoUpdate' => $this->getInput('configAutoUpdate', helper::FILTER_BOOLEAN),
- 'autoUpdateHtaccess' => $this->getInput('configAutoUpdateHtaccess', helper::FILTER_BOOLEAN),
- 'proxyType' => $this->getInput('configProxyType'),
- 'proxyUrl' => $this->getInput('configProxyUrl'),
- 'proxyPort' => $this->getInput('configProxyPort',helper::FILTER_INT),
- 'captchaStrong' => $this->getInput('configCaptchaStrong',helper::FILTER_BOOLEAN),
- 'autoDisconnect' => $this->getInput('configAutoDisconnect',helper::FILTER_BOOLEAN),
'smtp' => [
'enable' => $this->getInput('configSmtpEnable',helper::FILTER_BOOLEAN),
'host' => $this->getInput('configSmtpHost',helper::FILTER_STRING_SHORT),
@@ -474,12 +472,14 @@ class config extends common {
'seo' => [
'robots' => $this->getInput('configSeoRobots',helper::FILTER_BOOLEAN)
],
- 'connect' => [
+ 'safety' => [
'attempt' => $this->getInput('configConnectAttempt',helper::FILTER_INT),
'timeout' => $this->getInput('configConnectTimeout',helper::FILTER_INT),
'log' => $this->getInput('configConnectLog',helper::FILTER_BOOLEAN),
'anonymousIp' => $this->getInput('configConnectAnonymousIp',helper::FILTER_INT),
'captcha' => $this->getInput('configConnectCaptcha',helper::FILTER_BOOLEAN),
+ 'captchaStrong' => $this->getInput('configConnectCaptchaStrong',helper::FILTER_BOOLEAN),
+ 'autoDisconnect' => $this->getInput('configConnectAutoDisconnect',helper::FILTER_BOOLEAN),
],
'i18n' => [
'enable' => $this->getData(['config', 'i18n', 'enable'])
diff --git a/core/module/config/view/safety/safety.help.html b/core/module/config/view/connect/connect.help.html
similarity index 100%
rename from core/module/config/view/safety/safety.help.html
rename to core/module/config/view/connect/connect.help.html
diff --git a/core/module/config/view/safety/safety.php b/core/module/config/view/connect/connect.php
similarity index 76%
rename from core/module/config/view/safety/safety.php
rename to core/module/config/view/connect/connect.php
index 5db5f624..8b345ba8 100644
--- a/core/module/config/view/safety/safety.php
+++ b/core/module/config/view/connect/connect.php
@@ -1,22 +1,22 @@
-
+
Sécurité de la connexion
- $this->getData(['config', 'connect','captcha'])
]); ?>
- $this->getData(['config','captchaStrong']),
'help' => 'Option recommandée pour sécuriser la connexion. S\'applique à tous les captchas du site. Le captcha simple se limite à une addition de nombres de 0 à 10. Le captcha complexe utilise quatre opérations de nombres de 0 à 20. Activation recommandée.'
]); ?>
- $this->getData(['config','autoDisconnect']),
'help' => 'Déconnecte les sessions ouvertes précédemment sur d\'autres navigateurs ou terminaux. Activation recommandée.'
]); ?>
@@ -24,13 +24,13 @@
- 'Connexions successives',
'selected' => $this->getData(['config', 'connect', 'attempt'])
]); ?>
- 'Blocage après échecs',
'selected' => $this->getData(['config', 'connect', 'timeout'])
]); ?>
@@ -42,14 +42,14 @@
Après le nombre de tentatives autorisées, l\'IP et le compte sont bloqués.');
?>
- helper::baseUrl() . 'config/blacklistDownload',
'value' => 'Télécharger la liste',
'ico' => 'download'
]); ?>
- 'buttonRed',
'href' => helper::baseUrl() . 'config/blacklistReset',
'value' => 'Réinitialiser la liste',
@@ -66,26 +66,26 @@
Journalisation
- $this->getData(['config', 'connect', 'log'])
]); ?>
- 'Anonymat des adresses IP',
'selected' => $this->getData(['config', 'connect', 'anonymousIp']),
'help' => 'La réglementation française impose un anonymat de niveau 2'
]); ?>
- helper::baseUrl() . 'config/logDownload',
'value' => 'Télécharger le journal',
'ico' => 'download'
]); ?>
- 'buttonRed',
'href' => helper::baseUrl() . 'config/logReset',
'value' => 'Réinitialiser le journal',
diff --git a/core/module/config/view/index/index.css b/core/module/config/view/index/index.css
index f125f340..9d2c2fc4 100755
--- a/core/module/config/view/index/index.css
+++ b/core/module/config/view/index/index.css
@@ -16,3 +16,11 @@
/** NE PAS EFFACER
* admin.css
*/
+
+#setupContainer {
+ display: block;
+}
+
+#localeContainer, #socialContainer, #safetyContainer, #networkContainer {
+ display: none;
+}
\ No newline at end of file
diff --git a/core/module/config/view/index/index.js.php b/core/module/config/view/index/index.js.php
index 544b8ee6..52cf0bf0 100644
--- a/core/module/config/view/index/index.js.php
+++ b/core/module/config/view/index/index.js.php
@@ -87,4 +87,59 @@ $( document).ready(function() {
}
});
+ /**
+ * Captcha strong si captcha sélectionné
+ */
+ $("input[name=configConnectCaptcha]").on("change", function() {
+
+ if ($("input[name=configConnectCaptcha]").is(':checked')) {
+ $("#configConnectCaptchaStrongWrapper").addClass("disabled");
+ $("#configConnectCaptchaStrongWrapper").slideDown();
+ $( "#configConnectCaptchaStrong" ).prop( "checked", false );
+ } else {
+ $("#configConnectCaptchaStrongWrapper").removeClass("disabled");
+ $("#configConnectCaptchaStrongWrapper").slideUp();
+ }
+ });
+
+
+ /**
+ * Sélection de la page de configuration à afficher
+ */
+ $("#configSetupButton").on("click", function() {
+ $("#localeContainer").slideUp();
+ $("#socialContainer").slideUp();
+ $("#connectContainer").slideUp();
+ $("#networkContainer").slideUp();
+ $("#setupContainer").slideDown();
+ });
+ $("#configLocalButton").on("click", function() {
+ $("#setupContainer").slideUp();
+ $("#socialContainer").slideUp();
+ $("#connectContainer").slideUp();
+ $("#networkContainer").slideUp();
+ $("#localeContainer").slideDown();
+ });
+ $("#configSocialButton").on("click", function() {
+ $("#connectContainer").slideUp();
+ $("#setupContainer").slideUp();
+ $("#localeContainer").slideUp();
+ $("#networkContainer").slideUp();
+ $("#socialContainer").slideDown();
+ });
+ $("#configConnectButton").on("click", function() {
+ $("#setupContainer").slideUp();
+ $("#localeContainer").slideUp();
+ $("#socialContainer").slideUp();
+ $("#networkContainer").slideUp();
+ $("#connectContainer").slideDown();
+ });
+ $("#configNetworkButton").on("click", function() {
+ $("#setupContainer").slideUp();
+ $("#localeContainer").slideUp();
+ $("#socialContainer").slideUp();
+ $("#connectContainer").slideUp();
+ $("#networkContainer").slideDown();
+ });
+
});
diff --git a/core/module/config/view/index/index.php b/core/module/config/view/index/index.php
index e7661cd1..57ceb7af 100644
--- a/core/module/config/view/index/index.php
+++ b/core/module/config/view/index/index.php
@@ -23,32 +23,27 @@
- helper::baseUrl() . 'config/index',
+ 'Paramètres'
]); ?>
- helper::baseUrl() . 'config/locale',
+ 'Localisation'
]); ?>
- helper::baseUrl() . 'config/social',
+ 'Référencement'
]); ?>
- helper::baseUrl() . 'config/safety',
- 'value' => 'Sécurité'
+ 'Connexion'
]); ?>
- helper::baseUrl() . 'config/network',
+ 'Réseau'
]); ?>
@@ -59,6 +54,6 @@
-
+
\ No newline at end of file
diff --git a/core/module/config/view/locale/locale.php b/core/module/config/view/locale/locale.php
index e0dd66c6..fc5284a5 100644
--- a/core/module/config/view/locale/locale.php
+++ b/core/module/config/view/locale/locale.php
@@ -1,4 +1,4 @@
-
diff --git a/core/module/config/view/network/network.php b/core/module/config/view/network/network.php
index 5e096aa6..2c9f4ece 100644
--- a/core/module/config/view/network/network.php
+++ b/core/module/config/view/network/network.php
@@ -1,4 +1,4 @@
-
+
diff --git a/core/module/config/view/setup/setup.php b/core/module/config/view/setup/setup.php
index 558ada51..278733b0 100644
--- a/core/module/config/view/setup/setup.php
+++ b/core/module/config/view/setup/setup.php
@@ -1,4 +1,4 @@
-
+
@@ -21,7 +21,7 @@
]); ?>
- 'Fuseau horaire',
'selected' => $this->getData(['config', 'timezone']),
'help' => 'Le fuseau horaire est utile au bon référencement'
@@ -30,13 +30,13 @@
- $this->getData(['config', 'cookieConsent']),
'help' => 'Activation obligatoire selon les lois françaises sauf si vous utilisez votre propre système de consentement.'
]); ?>
- helper::checkRewrite(),
'help' => 'Vérifiez d\'abord que votre serveur autorise l\'URL rewriting (ce qui n\'est pas le cas chez Free).'
]); ?>
@@ -52,21 +52,21 @@
- $this->getData(['config', 'autoUpdate']),
'help' => 'La vérification est quotidienne. Option désactivée si la configuration du serveur ne le permet pas.',
'disabled' => !$updateError
]); ?>
- $this->getData(['config', 'autoUpdateHtaccess']),
'help' => 'Lors d\'une mise à jour automatique, conserve le fichier htaccess de la racine du site.',
'disabled' => !$updateError
]); ?>
- 'download-cloud',
'href' => helper::baseUrl() . 'install/update',
'value' => 'Mise à jour manuelle',
@@ -84,13 +84,13 @@
Maintenance
- $this->getData(['config', 'autoBackup']),
'help' => 'Une archive contenant le dossier /site/data est copiée dans le dossier \'site/backup\'. La sauvegarde est conservée pendant 30 jours.
Les fichiers du site ne sont pas sauvegardés automatiquement. Activation recommandée.'
]); ?>
- $this->getData(['config', 'maintenance'])
]); ?>
diff --git a/core/module/config/view/social/social.php b/core/module/config/view/social/social.php
index 1f925195..8b84a69c 100644
--- a/core/module/config/view/social/social.php
+++ b/core/module/config/view/social/social.php
@@ -1,4 +1,4 @@
-