Compare commits
325 Commits
37278e626f
...
418f5d74d2
Author | SHA1 | Date | |
---|---|---|---|
|
418f5d74d2 | ||
|
9367721d99 | ||
|
e9c3c2ba22 | ||
|
17a7b63761 | ||
|
2935a4dd8e | ||
|
f6c1e2a9f3 | ||
|
3facabaeca | ||
|
3b8b09df59 | ||
|
0f85512bb8 | ||
|
da87070418 | ||
|
2b8466428d | ||
|
d4d8f0eab5 | ||
|
668fda3d1d | ||
|
9b8d8c603f | ||
|
0feee84a23 | ||
|
f86eee254c | ||
|
29a2524231 | ||
|
2ad68ca01d | ||
|
d6f97b03bb | ||
|
78e6dd7adc | ||
|
f22eda7e6d | ||
|
beff8b1012 | ||
|
29036af835 | ||
|
f8683cc9e6 | ||
|
7be1dff6aa | ||
|
6d184fb0e4 | ||
|
3a637cc9fb | ||
|
ba7ceaa2cf | ||
|
e7bd96af39 | ||
|
7699120fe1 | ||
|
b2700fc989 | ||
|
5deec55290 | ||
|
4121504f60 | ||
|
b57d87859c | ||
|
aaf0e1c459 | ||
|
8e64e6637e | ||
|
8b2d09ed61 | ||
|
44c0eda419 | ||
|
bb7481aabe | ||
|
db9cb1f6ab | ||
|
73cc7c0a91 | ||
|
b74073645a | ||
|
3fe2e76741 | ||
|
cd73ac6996 | ||
|
812ad68832 | ||
|
59354b4556 | ||
|
c0643c03a0 | ||
|
d641d9d673 | ||
|
a78db57ef5 | ||
|
043df9922d | ||
|
e3749b8fc7 | ||
|
b8c3e7a266 | ||
|
1a201d127a | ||
|
1d404290c3 | ||
|
53a2b8c270 | ||
|
384c620ae7 | ||
|
9541002a39 | ||
|
b0272b4761 | ||
|
6b329558dd | ||
|
1c2e2d2d85 | ||
|
6f257433a5 | ||
|
0eafd2edfa | ||
|
19039a8eb2 | ||
|
07b7c5350f | ||
|
b85fdfcd9e | ||
|
9dcc5a28a6 | ||
|
51361afc12 | ||
|
949e4468c5 | ||
|
21d649946f | ||
|
89c86300d4 | ||
|
bb59346027 | ||
|
1251f247d3 | ||
|
639fa7c85f | ||
|
86830a4c9b | ||
|
68eb2cc061 | ||
|
dc31fc3ee6 | ||
|
41ae0e18e1 | ||
|
7d6a46c9b5 | ||
|
55bead4f4f | ||
|
1a5a163d4f | ||
|
5577b1b9b0 | ||
|
6f48ed51bd | ||
|
8a7503a7c1 | ||
|
6f9f447763 | ||
|
9b53b55682 | ||
|
a83d577f66 | ||
|
47e8016c51 | ||
|
30c3196460 | ||
|
d20bd6d14f | ||
|
c0df60b319 | ||
|
44fd79e3b2 | ||
|
4107cb0df0 | ||
|
f56790516e | ||
|
b02326f0cc | ||
|
b8366f34cb | ||
|
4215eb06b4 | ||
|
b35d48bdc2 | ||
|
b5640310b7 | ||
|
9a26cf73d6 | ||
|
a9ee02d1bc | ||
|
0af5e5663d | ||
|
7397630165 | ||
|
f41811a861 | ||
|
135df50a66 | ||
|
3c4e1f1294 | ||
|
d36a2048a6 | ||
|
ea8fd8e097 | ||
|
784d3b9cb8 | ||
|
34a26ea4ab | ||
|
972b86676e | ||
|
dd00425e33 | ||
|
d486674d73 | ||
|
159c7f82e2 | ||
|
7a31eb4ff1 | ||
|
8fce54024e | ||
|
747d0455f1 | ||
|
8d089a0dc5 | ||
|
01bffadc87 | ||
|
f4048cfb4e | ||
|
3f23765791 | ||
|
13b70d499c | ||
|
a7b7512ed5 | ||
|
20c2858c36 | ||
|
8eed8d73fb | ||
|
5e43d6fd21 | ||
|
0a755dc1fa | ||
|
66c2546b7a | ||
|
6634e99569 | ||
|
31987f4066 | ||
|
3508f3a6cf | ||
|
507912926d | ||
|
746163e0d1 | ||
|
ae98d2f1ae | ||
|
b192070782 | ||
|
23fa96a2b6 | ||
|
6fae1187e3 | ||
|
2f27ca0235 | ||
|
bbc727d400 | ||
|
4f6f4139bb | ||
|
cd39cfe53c | ||
|
17890bc81d | ||
|
b5532c8662 | ||
|
71e12a5ada | ||
|
567a70d909 | ||
|
3fefff219d | ||
|
1915f554b7 | ||
|
aff90ba298 | ||
|
5de144f947 | ||
|
8833dca44f | ||
|
7b40871927 | ||
|
cf6b37f49d | ||
|
1a97c3b477 | ||
|
f615a37473 | ||
|
e7c19df92e | ||
|
e5d838b345 | ||
|
fc1ac0c5e7 | ||
|
27e4b9db3b | ||
|
d1d0a485d7 | ||
|
dc3d7dbe7c | ||
|
c88fbe4092 | ||
|
cff5837d41 | ||
|
c46907396c | ||
|
3355e0311e | ||
|
772bda27e6 | ||
|
34aac7834a | ||
|
f6cf9c107a | ||
|
2fd69d0950 | ||
|
05f64946a6 | ||
|
f5a31309b9 | ||
|
2d41fad30d | ||
|
1d4e9a1862 | ||
|
d2f643634e | ||
|
8c8d42344d | ||
|
9596ca9932 | ||
|
a741f0ddcd | ||
|
cde72fe1ce | ||
|
e07285259b | ||
|
1cfdd115bb | ||
|
00ad2cc3a4 | ||
|
fcd20f61e5 | ||
|
2c7f2b6c96 | ||
|
024f7451e6 | ||
|
f17161f9e9 | ||
|
22dfce63b9 | ||
|
8abe700c42 | ||
|
5427853357 | ||
|
87d8f2a22a | ||
|
01cd75cfd0 | ||
|
0952e597e4 | ||
|
f382a5a16b | ||
|
96425a116f | ||
|
fdd52d206c | ||
|
23757e3fbc | ||
|
7e310da9c2 | ||
|
f80db3cacf | ||
|
c535d7560a | ||
|
cd41906adf | ||
|
97110dd032 | ||
|
dac78b6c02 | ||
|
4b296ff48f | ||
|
b6023ede0f | ||
|
617351290d | ||
|
0562fbe33c | ||
|
fa0323141b | ||
|
4be16c87e8 | ||
|
ccc5041dad | ||
|
5c6a90c0ac | ||
|
d4321076fc | ||
|
f9eb28f6f3 | ||
|
174e087fc3 | ||
|
e6f75275f2 | ||
|
1749b1265f | ||
|
a4a2973dc4 | ||
|
63f1c6844f | ||
|
6477265a8a | ||
|
1e2f6b9a6b | ||
|
2384367a68 | ||
|
f8fa03e7de | ||
|
5c35bd3c1d | ||
|
1051fa0731 | ||
|
93e2dd40e3 | ||
|
a056755826 | ||
|
62c0e29b44 | ||
|
b9bc252979 | ||
|
96d2fc2e0d | ||
|
d0c14aaa49 | ||
|
332127401f | ||
|
50fd8a3c9d | ||
|
5dfbe9a60d | ||
|
a2b2896d80 | ||
|
680af4c652 | ||
|
643a60ddd5 | ||
|
2c3124b462 | ||
|
5a151c577c | ||
|
fe2425bf5d | ||
|
fe7a6f3ca0 | ||
|
2f97898e6e | ||
|
61fb84d594 | ||
|
29a41a8d99 | ||
|
97c820c7d6 | ||
|
afeb66fd7d | ||
|
5291f058a7 | ||
|
72b82aa071 | ||
|
03568f6641 | ||
|
2171f1b6d6 | ||
|
7772b25d6a | ||
|
7aad2deb53 | ||
|
3d140e1a36 | ||
|
25f22f4ff2 | ||
|
0b66f0ab2e | ||
|
e181178a54 | ||
|
323042f563 | ||
|
b676ed401e | ||
|
f8430c9745 | ||
|
52f69a2b37 | ||
|
a66a2c516d | ||
|
303455aec5 | ||
|
975c702d2c | ||
|
5d2bde567f | ||
|
cde9187b0d | ||
|
da4e8fc46c | ||
|
e222a7ded2 | ||
|
cda2d93812 | ||
|
02951c7c66 | ||
|
f08650f148 | ||
|
62f58b16a0 | ||
|
bd43bf0e85 | ||
|
6f228d168d | ||
|
6f82ddc1a2 | ||
|
dc65a8e618 | ||
|
d5beaec9d7 | ||
|
78259f3da6 | ||
|
092c4053b2 | ||
|
0ffe4f7b40 | ||
|
a049fcb269 | ||
|
7938ba7645 | ||
|
d62ccb442f | ||
|
38d80dab96 | ||
|
a4c077db0b | ||
|
299f936f64 | ||
|
83d9980486 | ||
|
0d7b674e0f | ||
|
6dd3f034cb | ||
|
ad73150bc4 | ||
|
a7efdbf6c5 | ||
|
d6b2dc7e20 | ||
|
90d281b483 | ||
|
4387390dbc | ||
|
dca8fb57ab | ||
|
4a599c513c | ||
|
2e35c1fa2c | ||
|
ce610b2d0a | ||
|
529f495f3d | ||
|
01b83cd0f8 | ||
|
2899195ef8 | ||
|
f96e7377f8 | ||
|
e7ffeeefbd | ||
|
29ef8f06f5 | ||
|
125378ec93 | ||
|
a94d0b4433 | ||
|
c38766258a | ||
|
550a9c6462 | ||
|
0c9aadd621 | ||
|
c8ec4a7c77 | ||
|
42fd538ccb | ||
|
a371a3770e | ||
|
f1d1413314 | ||
|
91accd2c0d | ||
|
0f2bba19d2 | ||
|
4e3263b5fe | ||
|
fe8d473a76 | ||
|
a4ac385577 | ||
|
4c348e44f0 | ||
|
a28419225a | ||
|
43f2ccca4f | ||
|
52a22f5717 | ||
|
e44575d0ae | ||
|
3ea30e9268 | ||
|
ef141d72bf | ||
|
249e173b3e | ||
|
f32dbfc52d | ||
|
ef3e9db7f5 | ||
|
457b536fca | ||
|
23a1e929a3 | ||
|
329f252d82 |
10
.gitignore
vendored
@ -38,4 +38,12 @@ site/data/journal.log
|
||||
.DS_Store
|
||||
site/.DS_Store
|
||||
site/file/.DS_Store
|
||||
|
||||
site/data/es/locale.json
|
||||
site/data/es/module.json
|
||||
site/data/es/page.json
|
||||
site/data/en/locale.json
|
||||
site/data/en/module.json
|
||||
site/data/en/page.json
|
||||
site/data/de/locale.json
|
||||
site/data/de/module.json
|
||||
site/data/de/page.json
|
||||
|
30
CHANGES.md
@ -1,5 +1,31 @@
|
||||
# Changelog
|
||||
|
||||
## version 10.4.00
|
||||
Corrections :
|
||||
- Bug de pages non accessibles dans le menu suite à la création d'entrées fantômes dans le fichier de données de modules.
|
||||
- Nettoyage du fichiers des données de modules des entrées fantômes.
|
||||
- Thème : déformation des images en arrière-plan dans les modes responsives cover et contain lorsque la longueur de la page change. L'image en arrière-plan est désormais placée dans la balise html et l'option fixe s'active lorsque cover ou contain sont sélectionnés.
|
||||
- Thème : déformation du sélecteur de fichiers dans certains formats de page.
|
||||
- Module Form : mauvais affichage du guillemet et de l'apostrophe dans les noms des champs lors de l'édition.
|
||||
- Thème : faille CSRF, protection de la réinitialisation des fichiers de thème.
|
||||
- Modifications :
|
||||
- Filtrage des URL générées par facebook (FBCLID) occasionnant une erreur 404
|
||||
- Captcha arithmétique, activation recommandée dans la configuration.
|
||||
- Module User
|
||||
- Pour les articles de blog et de news, choix de la signature, nom+prenom ; nom+prenom ; id ; pseudo
|
||||
- Importation d'un liste d'utilisateur dans un fichier plat (CSV).
|
||||
- Module Blog :
|
||||
- Texte du commentaire enrichi.
|
||||
- Nombre maximal de caractère par commentaire.
|
||||
- Gestion des commentaires article par article.
|
||||
- Suppression des commentaires en masse.
|
||||
- Limiter l'édition des articles et des commentaires à l'id de l'éditeur
|
||||
- Approbation des commentaires
|
||||
- Gestion des thèmes :
|
||||
- Bouton de réinitialisation avec confirmation
|
||||
- Amélioration de la structure du flux RSS.
|
||||
|
||||
|
||||
## Version 10.3.13
|
||||
Modifications :
|
||||
- Système de données (JsonDB) :
|
||||
@ -93,11 +119,13 @@ Corrections :
|
||||
- Barre de membre déplacée à droite de la barre de menu.
|
||||
|
||||
## version 10.3.02
|
||||
- Correction :
|
||||
- Corrections :
|
||||
- Icône de pied de page github manquante.
|
||||
- Mauvaise redirection après changement de mot de passe d'un membre.
|
||||
- Modifications :
|
||||
- Nouvelles images de captcha.
|
||||
- Option de configuration, captcha demandé à la connexion.
|
||||
|
||||
- Méthode d'encodage UTF8.
|
||||
|
||||
## version 10.3.01
|
||||
|
11
README.md
@ -1,9 +1,9 @@
|
||||
|
||||
# ZwiiCMS 10.3.13
|
||||
# ZwiiCMS 10.4.00
|
||||
|
||||
Zwii est un CMS sans base de données (flat-file) qui permet de créer et gérer facilement un site web sans aucune connaissance en programmation.
|
||||
|
||||
ZwiiCMS a été créé par un développeur de talent, [Rémi Jean](https://remijean.fr/). Il est désormais maintenu par Fred Tempez aidé de la communauté.
|
||||
ZwiiCMS a été créé par un développeur de talent, [Rémi Jean](https://remijean.fr/). Il est désormais maintenu par Frédéric Tempez.
|
||||
|
||||
[Site](http://zwiicms.fr/) - [Forum](http://forum.zwiicms.com/) - [Version initiale](https://github.com/remijean/ZwiiCMS/) - [GitHub](https://github.com/fredtempez/ZwiiCMS)
|
||||
|
||||
@ -74,9 +74,9 @@ Pour revenir à la version 8, renommez ce fichier "data.json".
|
||||
[R] fr Dossier localisé
|
||||
[F] page.json Données des pages
|
||||
[F] module.json Données des modules de pages
|
||||
[F] admin.css Thème de la partie administration
|
||||
[F] admin.json Données de la partie administration
|
||||
[F] blacklist.json Données de connexion des comptes inconnus
|
||||
[F] admin.css Thème des pages d'administration
|
||||
[F] admin.json Données de thème des pages d'administration
|
||||
[F] blacklist.json Journalisation des tentatives de connexion avec des comptes inconnus
|
||||
[F] config.json Configuration du site
|
||||
[F] core.json Configuration du noyau
|
||||
[F] custom.css Feuille de style de la personnalisation avancée
|
||||
@ -84,6 +84,7 @@ Pour revenir à la version 8, renommez ce fichier "data.json".
|
||||
[F] theme.css Thème du site
|
||||
[F] theme.json Données du site
|
||||
[F] user.json Données des utilisateurs
|
||||
[F] .backup Marqueur de la sauvegarde des fichiers si présent
|
||||
[R] file Répertoire d'upload du gestionnaire de fichiers
|
||||
[R] source Ressources diverses
|
||||
[R] thumb Miniatures des images
|
||||
|
@ -132,8 +132,8 @@ class JsonDb extends \Prowebcraft\Dot
|
||||
touch($this->db);
|
||||
}
|
||||
// Backup file
|
||||
if ($this->config['backup']) {
|
||||
copy ($this->db, str_replace('json' , 'back.json', $this->db));
|
||||
if ($this->config['backup'] === true) {
|
||||
copy ($this->db, str_replace('json' , 'backup.json', $this->db));
|
||||
}
|
||||
if ( is_writable($this->db) ) {
|
||||
// 3 essais
|
||||
|
@ -32,7 +32,7 @@ class template {
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
/**
|
||||
* Crée un champ captcha
|
||||
* @param string $nameId Nom et id du champ
|
||||
* @param array $attributes Attributs ($key => $value)
|
||||
@ -47,29 +47,84 @@ class template {
|
||||
'id' => $nameId,
|
||||
'name' => $nameId,
|
||||
'value' => '',
|
||||
'limit' => false
|
||||
'limit' => false // captcha simple
|
||||
], $attributes);
|
||||
// Génère deux nombres pour le captcha
|
||||
$numbers = array(0,1,2,3,4,5,6,7,8,9,10,12,13,14,15,16,17,18,19,20);
|
||||
$letters = array('u','t','s','r','q','p','o','n','m','l','k','j','i','h','g','f','e','d','c','b','a');
|
||||
$limit = $attributes['limit'] ? count($letters)-1 : 10 ;
|
||||
mt_srand((float) microtime()*1000000);
|
||||
$firstNumber = mt_rand ( 0 , $limit );
|
||||
$secondNumber = mt_rand ( 0 , $limit );
|
||||
$result = $firstNumber + $secondNumber;
|
||||
|
||||
// Captcha quatre opérations
|
||||
// Limite addition et soustraction selon le type de captcha
|
||||
$numbers = [0,1,2,3,4,5,6,7,8,9,10,12,13,14,15,16,17,18,19,20];
|
||||
$letters = ['u','t','s','r','q','p','o','n','m','l','k','j','i','h','g','f','e','d','c','b','a'];
|
||||
$limit = $attributes['limit'] ? count($letters)-1 : 10;
|
||||
|
||||
// Tirage de l'opération
|
||||
mt_srand((float) microtime()*1000000);
|
||||
// Captcha simple limité à l'addition
|
||||
$operator = $attributes['limit'] ? mt_rand (1, 4) : 1;
|
||||
|
||||
// Limite si multiplication ou division
|
||||
if ($operator > 2) {
|
||||
$limit = 10;
|
||||
}
|
||||
|
||||
// Tirage des nombres
|
||||
mt_srand((float) microtime()*1000000);
|
||||
$firstNumber = mt_rand (1, $limit);
|
||||
mt_srand((float) microtime()*1000000);
|
||||
$secondNumber = mt_rand (1, $limit);
|
||||
|
||||
// Permutation si addition ou soustraction
|
||||
if (($operator < 3) and ($firstNumber < $secondNumber)) {
|
||||
$temp = $firstNumber;
|
||||
$firstNumber = $secondNumber;
|
||||
$secondNumber = $temp;
|
||||
}
|
||||
|
||||
// Icône de l'opérateur et calcul du résultat
|
||||
switch ($operator) {
|
||||
case 1:
|
||||
$operator = template::ico('plus');
|
||||
$result = $firstNumber + $secondNumber;
|
||||
break;
|
||||
case 2:
|
||||
$operator = template::ico('minus');
|
||||
$result = $firstNumber - $secondNumber;
|
||||
break;
|
||||
case 3:
|
||||
$operator = template::ico('cancel');
|
||||
$result = $firstNumber * $secondNumber;
|
||||
break;
|
||||
case 4:
|
||||
$operator = template::ico('divide');
|
||||
$limit2 = [10, 10, 6, 5, 4, 3, 2, 2, 2, 2];
|
||||
for ($i = 1; $i <= $firstNumber; $i++) {
|
||||
$limit = $limit2[$i-1];
|
||||
}
|
||||
mt_srand((float) microtime()*1000000);
|
||||
$secondNumber = mt_rand(1, $limit);
|
||||
$firstNumber = $firstNumber * $secondNumber;
|
||||
$result = $firstNumber / $secondNumber;
|
||||
break;
|
||||
}
|
||||
|
||||
// Hashage du résultat
|
||||
$result = password_hash($result, PASSWORD_BCRYPT);
|
||||
|
||||
// Codage des valeurs de l'opération
|
||||
$firstLetter = uniqid();
|
||||
$secondLetter = uniqid();
|
||||
// Masquage image source
|
||||
|
||||
// Masquage image source pour éviter un décodage
|
||||
copy ('core/vendor/zwiico/png/'.$letters[$firstNumber] . '.png', 'site/tmp/' . $firstLetter . '.png');
|
||||
copy ('core/vendor/zwiico/png/'.$letters[$secondNumber] . '.png', 'site/tmp/' . $secondLetter . '.png');
|
||||
|
||||
// Début du wrapper
|
||||
$html = '<div id="' . $attributes['id'] . 'Wrapper" class="captcha inputWrapper ' . $attributes['classWrapper'] . '">';
|
||||
// Label
|
||||
$html .= self::label($attributes['id'],
|
||||
'<img src="' . helper::baseUrl(false) . 'site/tmp/' . $firstLetter . '.png" />' . template::ico('plus') . '<img class="captchaNumber" src="' . helper::baseUrl(false) . 'site/tmp/' . $secondLetter . '.png" /> en chiffres ?', [
|
||||
'<img src="' . helper::baseUrl(false) . 'site/tmp/' . $firstLetter . '.png" /> <strong>' . $operator . '</strong> <img class="captchaNumber" src="' . helper::baseUrl(false) . 'site/tmp/' . $secondLetter . '.png" /> en chiffres ?', [
|
||||
'help' => $attributes['help']
|
||||
]);
|
||||
|
||||
// Notice
|
||||
$notice = '';
|
||||
if(array_key_exists($attributes['id'], common::$inputNotices)) {
|
||||
@ -77,29 +132,22 @@ class template {
|
||||
$attributes['class'] .= ' notice';
|
||||
}
|
||||
$html .= self::notice($attributes['id'], $notice);
|
||||
|
||||
// captcha
|
||||
$html .= sprintf(
|
||||
'<input type="text" %s>',
|
||||
helper::sprintAttributes($attributes)
|
||||
);
|
||||
// Champ résultat caché
|
||||
|
||||
// Champ résultat codé
|
||||
$html .= self::hidden($attributes['id'] . 'Result', [
|
||||
'value' => $result,
|
||||
'before' => false
|
||||
]);
|
||||
// Champs cachés contenant les nombres
|
||||
/*
|
||||
$html .= self::hidden($attributes['id'] . 'FirstNumber', [
|
||||
'value' => $firstNumber,
|
||||
'before' => false
|
||||
]);
|
||||
$html .= self::hidden($attributes['id'] . 'SecondNumber', [
|
||||
'value' => $secondNumber,
|
||||
'before' => false
|
||||
]);
|
||||
*/
|
||||
|
||||
// Fin du wrapper
|
||||
$html .= '</div>';
|
||||
|
||||
// Retourne le html
|
||||
return $html;
|
||||
}
|
||||
|
@ -472,4 +472,11 @@ $(document).ready(function(){
|
||||
$(changeIcon).addClass('zwiico-menu');
|
||||
};
|
||||
});
|
||||
|
||||
/**
|
||||
* Remove ID Facebook from URL
|
||||
*/
|
||||
if(/^\?fbclid=/.test(location.search))
|
||||
location.replace(location.href.replace(/\?fbclid.+/, ""));
|
||||
|
||||
});
|
||||
|
335
core/core.php
@ -26,6 +26,10 @@ class common {
|
||||
const GROUP_MEMBER = 1;
|
||||
const GROUP_MODERATOR = 2;
|
||||
const GROUP_ADMIN = 3;
|
||||
const SIGNATURE_ID = 1;
|
||||
const SIGNATURE_PSEUDO = 2;
|
||||
const SIGNATURE_FIRSTLASTNAME = 3;
|
||||
const SIGNATURE_LASTFIRSTNAME = 4;
|
||||
// Dossier de travail
|
||||
const BACKUP_DIR = 'site/backup/';
|
||||
const DATA_DIR = 'site/data/';
|
||||
@ -40,7 +44,7 @@ class common {
|
||||
const ACCESS_TIMER = 1800;
|
||||
|
||||
// Numéro de version
|
||||
const ZWII_VERSION = '10.3.13';
|
||||
const ZWII_VERSION = '10.4.00.015';
|
||||
const ZWII_UPDATE_CHANNEL = "v10";
|
||||
|
||||
public static $actions = [];
|
||||
@ -51,23 +55,16 @@ class common {
|
||||
'page',
|
||||
'sitemap',
|
||||
'theme',
|
||||
'user'
|
||||
];
|
||||
public static $dataStage = [
|
||||
'config',
|
||||
'core',
|
||||
'module',
|
||||
'page',
|
||||
'user',
|
||||
'theme',
|
||||
'admin'
|
||||
'translate'
|
||||
];
|
||||
public static $accessList = [
|
||||
'user',
|
||||
'theme',
|
||||
'config',
|
||||
'edit',
|
||||
'config'
|
||||
'config',
|
||||
'translate'
|
||||
];
|
||||
public static $accessExclude = [
|
||||
'login',
|
||||
@ -145,13 +142,43 @@ class common {
|
||||
self::GROUP_MODERATOR => 'Éditeur',
|
||||
self::GROUP_ADMIN => 'Administrateur'
|
||||
];
|
||||
// Langues proposées
|
||||
public static $i18nList = [
|
||||
'fr' => 'Français (fr)',
|
||||
'de' => 'Allemand (de)',
|
||||
'en' => 'Anglais (en)',
|
||||
'es' => 'Espagnol (es)',
|
||||
'it' => 'Italien (it)',
|
||||
'nl' => 'Néerlandais (nl)',
|
||||
'pt' => 'Portugais (pt)',
|
||||
];
|
||||
// Langue courante
|
||||
public static $i18nCurrent = 'fr';
|
||||
public static $timezone;
|
||||
private $url = '';
|
||||
// Données de site
|
||||
private $user = [];
|
||||
private $core = [];
|
||||
private $config = [];
|
||||
// Dossier localisé
|
||||
private $page = [];
|
||||
private $module = [];
|
||||
private $locale = [];
|
||||
|
||||
// Descripteur de données Entrées / Sorties
|
||||
// Liste ici tous les fichiers de données
|
||||
private $dataFiles = [
|
||||
'config' => '',
|
||||
'page' => '',
|
||||
'module' => '',
|
||||
'core' => '',
|
||||
'page' => '',
|
||||
'user' => '',
|
||||
'theme' => '',
|
||||
'admin' => '',
|
||||
'blacklist' => '',
|
||||
'locale' => ''
|
||||
];
|
||||
|
||||
/**
|
||||
* Constructeur commun
|
||||
@ -165,23 +192,37 @@ class common {
|
||||
$this->input['_COOKIE'] = $_COOKIE;
|
||||
}
|
||||
|
||||
|
||||
// Instanciation de la classe des entrées / sorties
|
||||
// Récupère les descripteurs
|
||||
foreach ($this->dataFiles as $keys => $value) {
|
||||
// Constructeur JsonDB
|
||||
$this->dataFiles[$keys] = new \Prowebcraft\JsonDb([
|
||||
'name' => $keys . '.json',
|
||||
'dir' => $this->dataPath ($keys,self::$i18nCurrent),
|
||||
'backup' => file_exists('site/data/.backup')
|
||||
]);;
|
||||
}
|
||||
|
||||
|
||||
// Import version 9
|
||||
if (file_exists(self::DATA_DIR . 'core.json') === true &&
|
||||
$this->getData(['core','dataVersion']) < 10000) {
|
||||
$keepUsers = isset($_SESSION['KEEP_USERS']) ? $_SESSION['KEEP_USERS'] : false;
|
||||
$this->importData($keepUsers);
|
||||
unset ($_SESSION['KEEP_USERS']);
|
||||
// Réinstaller htaccess
|
||||
copy('core/module/install/ressource/.htaccess', self::DATA_DIR . '.htaccess');
|
||||
common::$importNotices [] = "Importation réalisée avec succès" ;
|
||||
//echo '<script>window.location.replace("' . helper::baseUrl() . $this->getData(['config','homePageId']) . '")</script>';
|
||||
$this->getData(['core','dataVersion']) < 10000) {
|
||||
$keepUsers = isset($_SESSION['KEEP_USERS']) ? $_SESSION['KEEP_USERS'] : false;
|
||||
$this->importData($keepUsers);
|
||||
unset ($_SESSION['KEEP_USERS']);
|
||||
// Réinstaller htaccess
|
||||
copy('core/module/install/ressource/.htaccess', self::DATA_DIR . '.htaccess');
|
||||
common::$importNotices [] = "Importation réalisée avec succès" ;
|
||||
//echo '<script>window.location.replace("' . helper::baseUrl() . $this->getData(['config','homePageId']) . '")</script>';
|
||||
}
|
||||
|
||||
// Installation fraîche, initialisation des modules manquants
|
||||
// La langue d'installation par défaut est fr
|
||||
foreach (self::$dataStage as $stageId) {
|
||||
$folder = $this->dirData ($stageId, 'fr');
|
||||
foreach ($this->dataFiles as $stageId => $item) {
|
||||
$folder = $this->dataPath ($stageId, self::$i18nCurrent);
|
||||
if (file_exists($folder . $stageId .'.json') === false) {
|
||||
$this->initData($stageId,'fr');
|
||||
$this->initData($stageId,self::$i18nCurrent);
|
||||
common::$coreNotices [] = $stageId ;
|
||||
}
|
||||
}
|
||||
@ -191,10 +232,6 @@ class common {
|
||||
$this->user = $this->getData(['user', $this->getInput('ZWII_USER_ID')]);
|
||||
}
|
||||
|
||||
// Mise en cache des pages et des modules
|
||||
$this->page = $this->getCache('page');
|
||||
$this->module = $this->getCache('module');
|
||||
|
||||
// Construit la liste des pages parents/enfants
|
||||
if($this->hierarchy['all'] === []) {
|
||||
$pages = helper::arrayCollumn($this->getData(['page']), 'position', 'SORT_ASC');
|
||||
@ -255,7 +292,7 @@ class common {
|
||||
$this->url = $url;
|
||||
}
|
||||
else {
|
||||
$this->url = $this->getData(['config', 'homePageId']);
|
||||
$this->url = $this->getData(['locale', 'homePageId']);
|
||||
}
|
||||
}
|
||||
|
||||
@ -321,14 +358,9 @@ class common {
|
||||
* @param array $keys Clé(s) des données
|
||||
*/
|
||||
public function deleteData($keys) {
|
||||
//Retourne une chaine contenant le dossier à créer
|
||||
$folder = $this->dirData ($keys[0],'fr');
|
||||
// Constructeur JsonDB
|
||||
$db = new \Prowebcraft\JsonDb([
|
||||
'name' => $keys[0] . '.json',
|
||||
'dir' => $folder,
|
||||
'backup' => true
|
||||
]);
|
||||
// Descripteur
|
||||
$db = $this->dataFiles[$keys[0]];
|
||||
// Aiguillage
|
||||
switch(count($keys)) {
|
||||
case 1:
|
||||
$db->delete($keys[0], true);
|
||||
@ -362,38 +394,10 @@ class common {
|
||||
public function getData($keys = []) {
|
||||
|
||||
if (count($keys) >= 1) {
|
||||
|
||||
/**
|
||||
* Lecture dans le cache, page et module
|
||||
*/
|
||||
if ($keys[0] === 'page' ||
|
||||
$keys[0] === 'module' ) {
|
||||
// Décent dans les niveaux de la variable $data
|
||||
$data = array_merge ($this->page , $this->module);
|
||||
foreach($keys as $key) {
|
||||
// Si aucune donnée n'existe retourne null
|
||||
if(isset($data[$key]) === false) {
|
||||
return null;
|
||||
}
|
||||
// Sinon décent dans les niveaux
|
||||
else {
|
||||
$data = $data[$key];
|
||||
}
|
||||
}
|
||||
// Retourne les données
|
||||
return $data;
|
||||
}
|
||||
|
||||
/**
|
||||
* Lecture directe
|
||||
*/
|
||||
//Retourne une chaine contenant le dossier à créer
|
||||
$folder = $this->dirData ($keys[0],'fr');
|
||||
// Constructeur JsonDB
|
||||
$db = new \Prowebcraft\JsonDb([
|
||||
'name' => $keys[0] . '.json',
|
||||
'dir' => $folder
|
||||
]);
|
||||
$db = $this->dataFiles[$keys[0]];
|
||||
switch(count($keys)) {
|
||||
case 1:
|
||||
$tempData = $db->get($keys[0]);
|
||||
@ -416,27 +420,14 @@ class common {
|
||||
case 7:
|
||||
$tempData = $db->get($keys[0].'.'.$keys[1].'.'.$keys[2].'.'.$keys[3].'.'.$keys[4].'.'.$keys[5].'.'.$keys[6]);
|
||||
break;
|
||||
case 8:
|
||||
$tempData = $db->get($keys[0].'.'.$keys[1].'.'.$keys[2].'.'.$keys[3].'.'.$keys[4].'.'.$keys[5].'.'.$keys[6].'.'.$keys[7]);
|
||||
break;
|
||||
}
|
||||
return $tempData;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Lecture des fichiers de données de page et mise ne cache
|
||||
* @param @return string données des pages
|
||||
*/
|
||||
public function getCache($data) {
|
||||
$folder = $this->dirData ($data,'fr');
|
||||
// Constructeur JsonDB
|
||||
$db = new \Prowebcraft\JsonDb([
|
||||
'name' => $data . '.json',
|
||||
'dir' => $folder
|
||||
]);
|
||||
$tempData = $db->get($data);
|
||||
return [$data => $tempData];
|
||||
}
|
||||
|
||||
/*
|
||||
* Dummy function
|
||||
* Compatibilité des modules avec v8 et v9
|
||||
@ -691,10 +682,11 @@ class common {
|
||||
* @param $lang langue des pages
|
||||
* @return string du dossier à créer
|
||||
*/
|
||||
public function dirData($id, $lang) {
|
||||
public function dataPath($id, $lang) {
|
||||
// Sauf pour les pages et les modules
|
||||
if ($id === 'page' ||
|
||||
$id === 'module') {
|
||||
$id === 'module' ||
|
||||
$id === 'locale' ) {
|
||||
$folder = self::DATA_DIR . $lang . '/' ;
|
||||
} else {
|
||||
$folder = self::DATA_DIR;
|
||||
@ -908,9 +900,9 @@ class common {
|
||||
// Fin SMTP
|
||||
} else {
|
||||
$host = str_replace('www.', '', $_SERVER['HTTP_HOST']);
|
||||
$mail->setFrom('no-reply@' . $host, $this->getData(['config', 'title']));
|
||||
$mail->setFrom('no-reply@' . $host, $this->getData(['locale', 'title']));
|
||||
if (is_null($replyTo)) {
|
||||
$mail->addReplyTo('no-reply@' . $host, $this->getData(['config', 'title']));
|
||||
$mail->addReplyTo('no-reply@' . $host, $this->getData(['locale', 'title']));
|
||||
} else {
|
||||
$mail->addReplyTo($replyTo);
|
||||
}
|
||||
@ -956,15 +948,10 @@ class common {
|
||||
return false;
|
||||
}
|
||||
|
||||
//Retourne une chaine contenant le dossier à créer
|
||||
$folder = $this->dirData ($keys[0],'fr');
|
||||
// Constructeur JsonDB
|
||||
$db = new \Prowebcraft\JsonDb([
|
||||
'name' => $keys[0] . '.json',
|
||||
'dir' => $folder,
|
||||
'backup' => true
|
||||
]);
|
||||
// Descripteur
|
||||
$db = $this->dataFiles[$keys[0]];
|
||||
|
||||
// Aiguillage
|
||||
switch(count($keys)) {
|
||||
case 2:
|
||||
$db->set($keys[0],$keys[1], true);
|
||||
@ -984,6 +971,10 @@ class common {
|
||||
case 7:
|
||||
$db->set($keys[0].'.'.$keys[1].'.'.$keys[2].'.'.$keys[3].'.'.$keys[4].'.'.$keys[5],$keys[6], true);
|
||||
break;
|
||||
case 8:
|
||||
$db->set($keys[0].'.'.$keys[1].'.'.$keys[2].'.'.$keys[3].'.'.$keys[4].'.'.$keys[5].'.'.$keys[6],$keys[7] );
|
||||
$db->save();
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
@ -1003,12 +994,7 @@ class common {
|
||||
if (!file_exists(self::DATA_DIR . '/' . $lang)) {
|
||||
mkdir (self::DATA_DIR . '/' . $lang);
|
||||
}
|
||||
$folder = $this->dirData ($module,$lang);
|
||||
// Constructeur JsonDB
|
||||
$db = new \Prowebcraft\JsonDb([
|
||||
'name' => $module . '.json',
|
||||
'dir' => $folder
|
||||
]);
|
||||
$db = $this->dataFiles[$module];
|
||||
if ($sampleSite === true) {
|
||||
$db->set($module,init::$siteData[$module]);
|
||||
} else {
|
||||
@ -1483,12 +1469,105 @@ class common {
|
||||
}
|
||||
$this->setData(['core', 'dataVersion', 10306]);
|
||||
}
|
||||
|
||||
// Version 10.3.08
|
||||
if ($this->getData(['core', 'dataVersion']) < 10308) {
|
||||
// RAZ la mise à jour auto bug 10.3.07
|
||||
$this->setData(['core','updateAvailable', false]);
|
||||
$this->setData(['core', 'dataVersion', 10308]);
|
||||
}
|
||||
|
||||
// Version 10.4.00
|
||||
if ($this->getData(['core', 'dataVersion']) < 10400) {
|
||||
// Ajouter le prénom comme pseudo et le pseudo comme signature
|
||||
foreach($this->getData(['user']) as $userId => $userIds){
|
||||
$this->setData(['user',$userId,'pseudo',$this->getData(['user',$userId,'firstname'])]);
|
||||
$this->setData(['user',$userId,'signature',2]);
|
||||
}
|
||||
|
||||
// Ajouter les champs de blog v3
|
||||
// Liste des pages dans pageList
|
||||
$pageList = array();
|
||||
foreach ($this->getHierarchy(null,null,null) as $parentKey=>$parentValue) {
|
||||
$pageList [] = $parentKey;
|
||||
foreach ($parentValue as $childKey) {
|
||||
$pageList [] = $childKey;
|
||||
}
|
||||
}
|
||||
// Parcourir pageList et rechercher les modules de blog
|
||||
|
||||
foreach ($pageList as $parentKey => $parent) {
|
||||
//La page est un blog
|
||||
if ($this->getData(['page',$parent,'moduleId']) === 'blog' ) {
|
||||
$articleIds = array_keys(helper::arrayCollumn($this->getData(['module', $parent, 'posts']), 'publishedOn', 'SORT_DESC'));
|
||||
foreach ($articleIds as $key => $article) {
|
||||
// Droits les deux groupes
|
||||
$this->setData(['module', $parent, 'posts', $article,'editConsent', 3]);
|
||||
// Limite de taille 500
|
||||
$this->setData(['module', $parent, 'posts', $article,'commentMaxlength', '500']);
|
||||
// Pas d'approbation des commentaires
|
||||
$this->setData(['module', $parent, 'posts', $article,'commentApproved', false ]);
|
||||
// pas de notification
|
||||
$this->setData(['module', $parent, 'posts', $article,'commentNotification', false ]);
|
||||
// groupe de notification
|
||||
$this->setData(['module', $parent, 'posts', $article,'commentGroupNotification', 3 ]);
|
||||
}
|
||||
|
||||
// Traitement des commentaires
|
||||
if ( is_array($this->getData(['module', $parent, 'posts', $article,'comment'])) ) {
|
||||
foreach($this->getData(['module', $parent, 'posts', $article,'comment']) as $commentId => $comment) {
|
||||
// Approbation
|
||||
$this->setData(['module', $parent, 'posts', $article,'comment', $commentId, 'approval', true ]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Création du fichier locale.json
|
||||
$this->setData(['locale','homePageId',$this->getData(['config','homePageId'])]);
|
||||
$this->setData(['locale','page404',$this->getData(['config','page404'])]);
|
||||
$this->setData(['locale','page403',$this->getData(['config','page403'])]);
|
||||
$this->setData(['locale','page302',$this->getData(['config','page302'])]);
|
||||
$this->setData(['locale','legalPageId',$this->getData(['config','legalPageId'])]);
|
||||
$this->setData(['locale','searchPageId',$this->getData(['config','searchPageId'])]);
|
||||
$this->setData(['locale','metaDescription',$this->getData(['config','metaDescription'])]);
|
||||
$this->setData(['locale','title',$this->getData(['config','title'])]);
|
||||
|
||||
// Renommer les fichier de backup
|
||||
if ($this->getInput('configAdvancedFileBackup', helper::FILTER_BOOLEAN) === false) {
|
||||
$path = realpath('site/data');
|
||||
foreach (new RecursiveIteratorIterator(new RecursiveDirectoryIterator($path)) as $filename)
|
||||
{
|
||||
if (strpos($filename,'back.json')) {
|
||||
rename($filename, str_replace('back.json','backup.json',$filename));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Supprimer les fichiers CSS devenus inutiles du module search
|
||||
if (file_exists('module/search/ressource/theme.css') )
|
||||
unlink('module/search/ressource/theme.css');
|
||||
if (file_exists('module/search/ressource/vartheme.css') )
|
||||
unlink('module/search/ressource/vartheme.css');
|
||||
$this->deleteData(['theme','search','keywordColor']);
|
||||
|
||||
// Nettoyer les modules avec des données null
|
||||
|
||||
$modules = $this->getData(['module']);
|
||||
foreach($modules as $key => $value) {
|
||||
if (is_null($value) ) {
|
||||
unset($modules[$key]);
|
||||
}
|
||||
}
|
||||
$this->setData (['module',$modules]);
|
||||
|
||||
$this->setData(['core', 'dataVersion', 10400]);
|
||||
|
||||
/**
|
||||
* mettre à jour defaultdata
|
||||
*/
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -1568,20 +1647,27 @@ class core extends common {
|
||||
$css = '/*' . md5(json_encode($this->getData(['theme']))) . '*/';
|
||||
// Import des polices de caractères
|
||||
$css .= '@import url("https://fonts.googleapis.com/css?family=' . $this->getData(['theme', 'text', 'font']) . '|' . $this->getData(['theme', 'title', 'font']) . '|' . $this->getData(['theme', 'header', 'font']) . '|' . $this->getData(['theme', 'menu', 'font']) . '");';
|
||||
// Fond du site
|
||||
// Fond du body
|
||||
$colors = helper::colorVariants($this->getData(['theme', 'body', 'backgroundColor']));
|
||||
$css .= 'body,div.mce-edit-area{background-color:' . $colors['normal'] . ';font-family:"' . str_replace('+', ' ', $this->getData(['theme', 'text', 'font'])) . '",sans-serif}';
|
||||
// Fond TinyMCe
|
||||
$css .= 'div.mce-edit-area{background-color:' . $colors['normal'] . ' !important}';
|
||||
// Body
|
||||
$css .= 'body{font-family:"' . str_replace('+', ' ', $this->getData(['theme', 'text', 'font'])) . '",sans-serif}';
|
||||
if($themeBodyImage = $this->getData(['theme', 'body', 'image'])) {
|
||||
$css .= 'body,div.mce-edit-area{background-image:url("../file/source/' . $themeBodyImage . '");background-position:' . $this->getData(['theme', 'body', 'imagePosition']) . ';background-attachment:' . $this->getData(['theme', 'body', 'imageAttachment']) . ';background-size:' . $this->getData(['theme', 'body', 'imageSize']) . ';background-repeat:' . $this->getData(['theme', 'body', 'imageRepeat']) . '}';
|
||||
$css .= 'div.mce-edit-area{background-image:url("../file/source/' . $themeBodyImage . '") !important;background-position:' . $this->getData(['theme', 'body', 'imagePosition']) . ';background-attachment:' . $this->getData(['theme', 'body', 'imageAttachment']) . ';background-size:' . $this->getData(['theme', 'body', 'imageSize']) . ';background-repeat:' . $this->getData(['theme', 'body', 'imageRepeat']) . '}';
|
||||
// Image dans html pour éviter les déformations.
|
||||
$css .= 'html{background-image:url("../file/source/' . $themeBodyImage . '");background-position:' . $this->getData(['theme', 'body', 'imagePosition']) . ';background-attachment:' . $this->getData(['theme', 'body', 'imageAttachment']) . ';background-size:' . $this->getData(['theme', 'body', 'imageSize']) . ';background-repeat:' . $this->getData(['theme', 'body', 'imageRepeat']) . '}';
|
||||
// Couleur du body transparente
|
||||
$css .= 'body{background-color: rgba(0,0,0,0)}';
|
||||
} else {
|
||||
// Pas d'image couleur du body
|
||||
$css .= 'html{background-color:' . $colors['normal'] . ';}';
|
||||
}
|
||||
// Icône BacktoTop
|
||||
$css .= '#backToTop {background-color:' .$this->getData(['theme', 'body', 'toTopbackgroundColor']). ';color:'.$this->getData(['theme', 'body', 'toTopColor']).';}';
|
||||
// Site
|
||||
$colors = helper::colorVariants($this->getData(['theme', 'text', 'linkColor']));
|
||||
$css .= 'a{color:' . $colors['normal'] . '}';
|
||||
// Fond TinyMCe
|
||||
$css .= 'div.mce-edit-area{background-color:' . $colors['normal'] . ' !important}';
|
||||
$css .= 'div.mce-edit-area{background-color:' . $colors['normal'] . ';font-family:"' . str_replace('+', ' ', $this->getData(['theme', 'text', 'font'])) . '",sans-serif}';
|
||||
//$css .= 'a:hover:not(.inputFile, button){color:' . $colors['darken'] . '}';
|
||||
$css .= 'body,.row > div{font-size:' . $this->getData(['theme', 'text', 'fontSize']) . '}';
|
||||
$css .= 'body{color:' . $this->getData(['theme', 'text', 'textColor']) . '}';
|
||||
@ -1592,7 +1678,7 @@ class core extends common {
|
||||
//$css .= '.button.buttonGrey,.button.buttonGrey:hover{color:' . $this->getData(['theme', 'text', 'textColor']) . '}';
|
||||
$css .= '.container{max-width:' . $this->getData(['theme', 'site', 'width']) . '}';
|
||||
$margin = $this->getData(['theme', 'site', 'margin']) ? '0' : '20px';
|
||||
$css .= $this->getData(['theme', 'site', 'width']) === '100%' ? '#site.light{margin:60px auto !important;}#site{margin:0 auto !important;} body{margin:0 auto !important;} #bar{margin:0 auto !important;} body > header{margin:0 auto !important;} body > nav {margin: 0 auto !important;} body > footer {margin:0 auto !important;}': "#site.light{margin: 60px auto !important;}#site{margin: " . $margin . " auto !important;} body{margin:0px 10px;} #bar{margin: 0 -10px;} body > header{margin: 0 -10px;} body > nav {margin: 0 -10px;} body > footer {margin: 0 -10px;} ";
|
||||
$css .= $this->getData(['theme', 'site', 'width']) === '100%' ? '#site.light{margin:5% auto !important;}#site{margin:0 auto !important;} body{margin:0 auto !important;} #bar{margin:0 auto !important;} body > header{margin:0 auto !important;} body > nav {margin: 0 auto !important;} body > footer {margin:0 auto !important;}': "#site.light{margin: 5% auto !important;}#site{margin: " . $margin . " auto !important;} body{margin:0px 10px;} #bar{margin: 0 -10px;} body > header{margin: 0 -10px;} body > nav {margin: 0 -10px;} body > footer {margin: 0 -10px;} ";
|
||||
$css .= $this->getData(['theme', 'site', 'width']) === '750px' ? '.button, button{font-size:0.8em;}' : '';
|
||||
$css .= '#site{background-color:' . $this->getData(['theme', 'site', 'backgroundColor']) . ';border-radius:' . $this->getData(['theme', 'site', 'radius']) . ';box-shadow:' . $this->getData(['theme', 'site', 'shadow']) . ' #212223;}';
|
||||
$css .= '.editorWysiwyg {background-color:' . $this->getData(['theme', 'site', 'backgroundColor']) . ';}';
|
||||
@ -1726,7 +1812,7 @@ class core extends common {
|
||||
$colors = helper::colorVariants($this->getData(['admin','backgroundColorButtonRed']));
|
||||
$css .= '.button.buttonRed {background-color: ' . $colors['normal'] . ';color: ' . $colors['text'] . ';}.button.buttonRed:hover {background-color:' . $colors['darken'] . ';color:' . $colors['text'] . ';}.button.buttonRed:active {background-color:' . $colors['veryDarken'] . ';color:' . $colors['text'] . ';}';
|
||||
$colors = helper::colorVariants($this->getData(['admin','backgroundColorButtonGreen']));
|
||||
$css .= 'button[type=submit] {background-color: ' . $colors['normal'] . ';color: ' . $colors['text'] . ';}button[type=submit]:hover {background-color: ' . $colors['darken'] . ';color: ' . $colors['text'] .';}button[type=submit]:active {background-color: ' . $colors['darken'] . ';color: ' .$colors['text'] .';}';
|
||||
$css .= '.button.buttonGreen, button[type=submit] {background-color: ' . $colors['normal'] . ';color: ' . $colors['text'] . ';}.button.buttonGreen:hover, button[type=submit]:hover {background-color: ' . $colors['darken'] . ';color: ' . $colors['text'] .';}.button.buttonGreen:active, button[type=submit]:active {background-color: ' . $colors['darken'] . ';color: ' .$colors['text'] .';}';
|
||||
$colors = helper::colorVariants($this->getData(['admin','backgroundBlockColor']));
|
||||
$css .= '.block {border: 1px solid ' . $this->getData(['admin','borderBlockColor']) . ';}.block h4 {background-color: ' . $colors['normal'] . ';color:' . $colors['text'] . ';}';
|
||||
$css .= 'table tr,input[type=email],input[type=text],input[type=password],select:not(#barSelectPage),textarea:not(.editorWysiwyg),.inputFile{background-color: ' . $colors['normal'] . ';color:' . $colors['text'] . ';border: 1px solid ' . $this->getData(['admin','borderBlockColor']) . ';}';
|
||||
@ -1826,14 +1912,14 @@ class core extends common {
|
||||
$access = true;
|
||||
}
|
||||
else {
|
||||
if($this->getUrl(0) === $this->getData(['config', 'homePageId'])) {
|
||||
if($this->getUrl(0) === $this->getData(['locale', 'homePageId'])) {
|
||||
$access = 'login';
|
||||
}
|
||||
else {
|
||||
$access = false;
|
||||
}
|
||||
}
|
||||
// Empêcher l'accès aux page désactivée par URL directe
|
||||
// Empêcher l'accès aux pages désactivées par URL directe
|
||||
if ( ( $this->getData(['page', $this->getUrl(0),'disable']) === true
|
||||
AND $this->getUser('password') !== $this->getInput('ZWII_USER_PASSWORD')
|
||||
) OR (
|
||||
@ -2063,6 +2149,7 @@ class core extends common {
|
||||
'vendor' => array_merge($this->output['vendor'], $output['vendor'])
|
||||
]);
|
||||
}
|
||||
|
||||
if($output['title'] !== null) {
|
||||
$this->addOutput([
|
||||
'title' => $output['title']
|
||||
@ -2082,6 +2169,7 @@ class core extends common {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Erreurs
|
||||
if($access === 'login') {
|
||||
http_response_code(302);
|
||||
@ -2096,10 +2184,10 @@ class core extends common {
|
||||
'content' => template::speech('La page <strong>' . $accessInfo['pageId'] . '</strong> est ouverte par l\'utilisateur <strong>' . $accessInfo['userName'] . '</strong>')
|
||||
]);
|
||||
} else {
|
||||
if ( $this->getData(['config','page403']) !== 'none'
|
||||
AND $this->getData(['page',$this->getData(['config','page403'])]))
|
||||
if ( $this->getData(['locale','page403']) !== 'none'
|
||||
AND $this->getData(['page',$this->getData(['locale','page403'])]))
|
||||
{
|
||||
header('Location:' . helper::baseUrl() . $this->getData(['config','page403']));
|
||||
header('Location:' . helper::baseUrl() . $this->getData(['locale','page403']));
|
||||
} else {
|
||||
$this->addOutput([
|
||||
'title' => 'Erreur 403',
|
||||
@ -2109,10 +2197,10 @@ class core extends common {
|
||||
}
|
||||
} elseif ($this->output['content'] === '') {
|
||||
http_response_code(404);
|
||||
if ( $this->getData(['config','page404']) !== 'none'
|
||||
AND $this->getData(['page',$this->getData(['config','page404'])]))
|
||||
if ( $this->getData(['locale','page404']) !== 'none'
|
||||
AND $this->getData(['page',$this->getData(['locale','page404'])]))
|
||||
{
|
||||
header('Location:' . helper::baseUrl() . $this->getData(['config','page404']));
|
||||
header('Location:' . helper::baseUrl() . $this->getData(['locale','page404']));
|
||||
} else {
|
||||
$this->addOutput([
|
||||
'title' => 'Erreur 404',
|
||||
@ -2124,18 +2212,18 @@ class core extends common {
|
||||
if($this->output['metaTitle'] === '') {
|
||||
if($this->output['title']) {
|
||||
$this->addOutput([
|
||||
'metaTitle' => strip_tags($this->output['title']) . ' - ' . $this->getData(['config', 'title'])
|
||||
'metaTitle' => strip_tags($this->output['title']) . ' - ' . $this->getData(['locale', 'title'])
|
||||
]);
|
||||
}
|
||||
else {
|
||||
$this->addOutput([
|
||||
'metaTitle' => $this->getData(['config', 'title'])
|
||||
'metaTitle' => $this->getData(['locale', 'title'])
|
||||
]);
|
||||
}
|
||||
}
|
||||
if($this->output['metaDescription'] === '') {
|
||||
$this->addOutput([
|
||||
'metaDescription' => $this->getData(['config', 'metaDescription'])
|
||||
'metaDescription' => $this->getData(['locale', 'metaDescription'])
|
||||
]);
|
||||
}
|
||||
|
||||
@ -2215,10 +2303,13 @@ class layout extends common {
|
||||
) {
|
||||
echo '<h1 id="sectionTitle">' . $this->core->output['title'] . '</h1>';
|
||||
}
|
||||
|
||||
echo $this->core->output['content'];
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Affiche le contenu de la barre gauche
|
||||
*
|
||||
@ -2299,15 +2390,15 @@ class layout extends common {
|
||||
// Affichage du module de recherche
|
||||
$items .= '<span id="footerDisplaySearch"';
|
||||
$items .= $this->getData(['theme','footer','displaySearch']) === false ? ' class="displayNone" >' : '>';
|
||||
if ($this->getData(['config','searchPageId']) !== 'none') {
|
||||
$items .= '<wbr> | <a href="' . helper::baseUrl() . $this->getData(['config','searchPageId']) . '" data-tippy-content="Rechercher dans le site" >Recherche</a>';
|
||||
if ($this->getData(['locale','searchPageId']) !== 'none') {
|
||||
$items .= '<wbr> | <a href="' . helper::baseUrl() . $this->getData(['locale','searchPageId']) . '" data-tippy-content="Rechercher dans le site" >Recherche</a>';
|
||||
}
|
||||
$items .= '</span>';
|
||||
// Affichage des mentions légales
|
||||
$items .= '<span id="footerDisplayLegal"';
|
||||
$items .= $this->getData(['theme','footer','displayLegal']) === false ? ' class="displayNone" >' : '>';
|
||||
if ($this->getData(['config','legalPageId']) !== 'none') {
|
||||
$items .= '<wbr> | <a href="' . helper::baseUrl() . $this->getData(['config','legalPageId']) . '" data-tippy-content="Mentions Légales">Mentions légales</a>';
|
||||
if ($this->getData(['locale','legalPageId']) !== 'none') {
|
||||
$items .= '<wbr> | <a href="' . helper::baseUrl() . $this->getData(['locale','legalPageId']) . '" data-tippy-content="Mentions Légales">Mentions légales</a>';
|
||||
}
|
||||
$items .= '</span>';
|
||||
// Affichage du lien de connexion
|
||||
@ -2808,6 +2899,7 @@ class layout extends common {
|
||||
if($this->getUser('group') >= self::GROUP_ADMIN) {
|
||||
$rightItems .= '<li><a href="' . helper::baseUrl() . 'user" data-tippy-content="Configurer les utilisateurs">' . template::ico('users') . '</a></li>';
|
||||
$rightItems .= '<li><a href="' . helper::baseUrl() . 'theme" data-tippy-content="Personnaliser les thèmes">' . template::ico('brush') . '</a></li>';
|
||||
//$rightItems .= '<li><a href="' . helper::baseUrl() . 'translate" data-tippy-content="Gestion des langues">' . template::ico('flag') . '</a></li>';
|
||||
$rightItems .= '<li><a href="' . helper::baseUrl() . 'config" data-tippy-content="Configurer le site">' . template::ico('cog-alt') . '</a></li>';
|
||||
// Mise à jour automatique
|
||||
$today = mktime(0, 0, 0);
|
||||
@ -2902,5 +2994,4 @@ class layout extends common {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
@ -1,6 +1,7 @@
|
||||
<?php $layout = new layout($this); ?>
|
||||
<?php $layout = new layout($this);
|
||||
$lan = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2); ?>
|
||||
<!DOCTYPE html>
|
||||
<html prefix="og: http://ogp.me/ns#" lang="fr">
|
||||
<html prefix="og: http://ogp.me/ns#" lang="<?php echo $lan;?>">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?php $layout = new layout($this); ?>
|
||||
<?php $layout = new layout($this);
|
||||
$lan = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2); ?>
|
||||
<!DOCTYPE html>
|
||||
<html prefix="og: http://ogp.me/ns#" lang="fr">
|
||||
<html prefix="og: http://ogp.me/ns#" lang="<?php echo $lan;?>">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
@ -83,7 +83,7 @@
|
||||
<table role="presentation" cellspacing="0" cellpadding="0" border="0" width="100%">
|
||||
<tr>
|
||||
<td style="border-bottom: 1px solid #EBEEF2; padding: 20px; font-family: 'Open Sans', sans-serif; font-size: 19px; line-height: 24px; text-align: center; color: #212223;">
|
||||
<?php echo $this->getData(['config', 'title']); ?>
|
||||
<?php echo $this->getData(['locale', 'title']); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@ -109,7 +109,7 @@
|
||||
<table role="presentation" cellspacing="0" cellpadding="0" border="0" width="100%">
|
||||
<tr>
|
||||
<td style="border-top: 1px solid #EBEEF2; padding: 20px; text-align: center; font-family: 'Open Sans', sans-serif; font-size: 12px; line-height: 17px; color: #212223;">
|
||||
<a href="<?php echo helper::baseUrl(false); ?>" target="_blank"><?php echo $this->getData(['config', 'title']); ?></a>
|
||||
<a href="<?php echo helper::baseUrl(false); ?>" target="_blank"><?php echo $this->getData(['locale', 'title']); ?></a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?php $layout = new layout($this); ?>
|
||||
<?php $layout = new layout($this);
|
||||
$lan = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2); ?>
|
||||
<!DOCTYPE html>
|
||||
<html prefix="og: http://ogp.me/ns#" lang="fr">
|
||||
<html prefix="og: http://ogp.me/ns#" lang="<?php echo $lan;?>">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
@ -14,6 +15,12 @@
|
||||
<link rel="stylesheet" href="<?php echo helper::baseUrl(false); ?>core/layout/common.css">
|
||||
<link rel="stylesheet" href="<?php echo helper::baseUrl(false) . self::DATA_DIR; ?>theme.css?<?php echo md5_file(self::DATA_DIR.'theme.css'); ?>">
|
||||
<link rel="stylesheet" href="<?php echo helper::baseUrl(false) . self::DATA_DIR; ?>custom.css?<?php echo md5_file(self::DATA_DIR.'custom.css'); ?>">
|
||||
<!-- Détection RSS -->
|
||||
<?php if ( ( $this->getData(['page', $this->getUrl(0), 'moduleId']) === 'blog'
|
||||
OR $this->getData(['page', $this->getUrl(0), 'moduleId']) === 'news' )
|
||||
AND $this->getData(['module', $this->getUrl(0), 'config', 'feeds']) === TRUE ): ?>
|
||||
<link rel="alternate" type="application/rss+xml" href="'<?php echo helper::baseUrl(). $this->getUrl(0) . '/rss';?>" title="fLUX rss">
|
||||
<?php endif; ?>
|
||||
<?php $layout->showStyle(); ?>
|
||||
<?php if (file_exists(self::DATA_DIR .'head.inc.html')) {
|
||||
include(self::DATA_DIR .'head.inc.html');
|
||||
@ -40,7 +47,7 @@
|
||||
<!-- Menu Burger -->
|
||||
<div id="toggle">
|
||||
<?php if ($this->getData(['theme','menu','burgerTitle']) === true ): ?>
|
||||
<div id="burgerText"><?php echo $this->getData(['config','title']);?></div>
|
||||
<div id="burgerText"><?php echo $this->getData(['locale','title']);?></div>
|
||||
<?php endif; ?>
|
||||
<?php echo template::ico('menu',null,null,'2em'); ?></div>
|
||||
<div id="menu" class="
|
||||
@ -53,6 +60,7 @@
|
||||
<?php if($this->getData(['theme', 'header', 'position']) === 'body'): ?>
|
||||
<!-- Bannière dans le fond du site -->
|
||||
<header>
|
||||
<?php //$layout->showi18n();?>
|
||||
<?php
|
||||
if ($this->getData(['theme','header','linkHomePage'])){
|
||||
echo "<a href='" . helper::baseUrl(false) . "'>" ;} ?>
|
||||
@ -62,7 +70,7 @@
|
||||
// Affiche toujours le titre de la bannière pour l'édition du thème
|
||||
OR ($this->getUrl(0) === 'theme' AND $this->getUrl(1) === 'header')
|
||||
): ?>
|
||||
<span id="themeHeaderTitle"><?php echo $this->getData(['config', 'title']); ?></span>
|
||||
<span id="themeHeaderTitle"><?php echo $this->getData(['locale', 'title']); ?></span>
|
||||
<?php else: ?>
|
||||
<span id="themeHeaderTitle"> </span>
|
||||
<?php endif; ?>
|
||||
@ -78,7 +86,7 @@
|
||||
<nav>
|
||||
<div id="toggle">
|
||||
<?php if ($this->getData(['theme','menu','burgerTitle']) === true ): ?>
|
||||
<div id="burgerText"><?php echo $this->getData(['config','title']);?></div>
|
||||
<div id="burgerText"><?php echo $this->getData(['locale','title']);?></div>
|
||||
<?php endif; ?>
|
||||
<?php echo template::ico('menu',null,null,'2em'); ?></div>
|
||||
<div id="menu" class="container"><?php $layout->showMenu(); ?></div>
|
||||
@ -91,7 +99,7 @@
|
||||
<nav>
|
||||
<div id="toggle">
|
||||
<?php if ($this->getData(['theme','menu','burgerTitle']) === true ): ?>
|
||||
<div id="burgerText"><?php echo $this->getData(['config','title']);?></div>
|
||||
<div id="burgerText"><?php echo $this->getData(['locale','title']);?></div>
|
||||
<?php endif; ?>
|
||||
<?php echo template::ico('menu',null,null,'2em'); ?></div>
|
||||
<div id="menu" class="container"><?php $layout->showMenu(); ?></div>
|
||||
@ -116,7 +124,7 @@
|
||||
// Affiche toujours le titre de la bannière pour l'édition du thème
|
||||
OR ($this->getUrl(0) === 'theme' AND $this->getUrl(1) === 'header')
|
||||
): ?>
|
||||
<span id="themeHeaderTitle"><?php echo $this->getData(['config', 'title']); ?></span>
|
||||
<span id="themeHeaderTitle"><?php echo $this->getData(['locale', 'title']); ?></span>
|
||||
<?php else: ?>
|
||||
<span id="themeHeaderTitle"> </span>
|
||||
<?php endif; ?>
|
||||
@ -138,7 +146,7 @@
|
||||
<nav <?php if($this->getData(['theme', 'menu', 'position']) === 'hide'): ?>class="displayNone"<?php endif; ?>>
|
||||
<div id="toggle">
|
||||
<?php if ($this->getData(['theme','menu','burgerTitle']) === true ): ?>
|
||||
<div id="burgerText"><?php echo $this->getData(['config','title']);?></div>
|
||||
<div id="burgerText"><?php echo $this->getData(['locale','title']);?></div>
|
||||
<?php endif; ?>
|
||||
<?php echo template::ico('menu',null,null,'2em'); ?></div>
|
||||
<div id="menu" class="container"><?php $layout->showMenu(); ?></div>
|
||||
@ -146,6 +154,7 @@
|
||||
<?php endif; ?>
|
||||
<!-- Corps de page -->
|
||||
<section>
|
||||
<?php //$layout->showi18n();?>
|
||||
<?php
|
||||
// Gabarit :
|
||||
// Récupérer la config de la page courante
|
||||
@ -186,7 +195,8 @@
|
||||
if ($blockleft !== "") :?>
|
||||
<div class="<?php echo $blockleft; ?>" id="contentLeft"><aside><?php $layout->showBarContentLeft(); ?></aside></div>
|
||||
<?php endif; ?>
|
||||
<div class="<?php echo $content; ?>" id="contentSite"><?php $layout->showContent();
|
||||
<div class="<?php echo $content; ?>" id="contentSite">
|
||||
<?php $layout->showContent();
|
||||
if (file_exists(self::DATA_DIR . 'body.inc.html')) {
|
||||
include(self::DATA_DIR . 'body.inc.html');
|
||||
}
|
||||
|
@ -22,6 +22,7 @@ class config extends common {
|
||||
'generateFiles' => self::GROUP_ADMIN,
|
||||
'updateRobots' => self::GROUP_ADMIN,
|
||||
'index' => self::GROUP_ADMIN,
|
||||
'advanced' => self::GROUP_ADMIN,
|
||||
'manage' => self::GROUP_ADMIN,
|
||||
'updateBaseUrl' => self::GROUP_ADMIN,
|
||||
'script' => self::GROUP_ADMIN,
|
||||
@ -203,7 +204,7 @@ class config extends common {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'notification' => ($successSitemap === true && $successRobots >= 100) ? 'Création réussie' : 'Echec d\'écriture',
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
'redirect' => helper::baseUrl() . 'config/advanced',
|
||||
'state' => ($successSitemap === true && $successRobots >=100) ? true : false
|
||||
]);
|
||||
}
|
||||
@ -294,7 +295,7 @@ class config extends common {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'notification' => $success === false ? 'Service inaccessible ou erreur d\'écriture de l\'image' : 'Image générée avec succès',
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
'redirect' => helper::baseUrl() . 'advanced',
|
||||
'state' => $success === false ? false : true
|
||||
]);
|
||||
}
|
||||
@ -409,17 +410,11 @@ class config extends common {
|
||||
// Soumission du formulaire
|
||||
if($this->isPost()) {
|
||||
$success = true;
|
||||
// Basculement en mise à jour auto
|
||||
// Remise à 0 du compteur
|
||||
if ($this->getData(['config','autoUpdate']) === false &&
|
||||
$this->getInput('configAutoUpdate', helper::FILTER_BOOLEAN) === true) {
|
||||
$this->setData(['core','lastAutoUpdate',0]);
|
||||
}
|
||||
// Empêcher la modification si défini dans footer
|
||||
if ( $this->getData(['theme','footer','displaySearch']) === true
|
||||
AND $this->getInput('configSearchPageId') === 'none'
|
||||
){
|
||||
$searchPageId = $this->getData(['config','searchPageId']);
|
||||
$searchPageId = $this->getData(['locale','searchPageId']);
|
||||
self::$inputNotices['configSearchPageId'] = 'Désactiver l\'option dans le pied de page';
|
||||
$success = false;
|
||||
} else {
|
||||
@ -429,7 +424,7 @@ class config extends common {
|
||||
if ( $this->getData(['theme','footer','displayLegal']) === true
|
||||
AND $this->getInput('configLegalPageId') === 'none'
|
||||
){
|
||||
$legalPageId = $this->getData(['config','legalPageId']);
|
||||
$legalPageId = $this->getData(['locale','legalPageId']);
|
||||
self::$inputNotices['configLegalPageId'] = 'Désactiver l\'option dans le pied de page';
|
||||
$success = false;
|
||||
} else {
|
||||
@ -437,59 +432,113 @@ class config extends common {
|
||||
}
|
||||
// Sauvegarder
|
||||
$this->setData([
|
||||
'config',
|
||||
'locale',
|
||||
[
|
||||
'homePageId' => $this->getInput('configHomePageId', helper::FILTER_ID, true),
|
||||
'page404' => $this->getInput('configPage404'),
|
||||
'page403' => $this->getInput('configPage403'),
|
||||
'page302' => $this->getInput('configPage302'),
|
||||
'analyticsId' => $this->getInput('configAnalyticsId'),
|
||||
'autoBackup' => $this->getInput('configAutoBackup', helper::FILTER_BOOLEAN),
|
||||
'maintenance' => $this->getInput('configMaintenance', helper::FILTER_BOOLEAN),
|
||||
'cookieConsent' => $this->getInput('configCookieConsent', helper::FILTER_BOOLEAN),
|
||||
'favicon' => $this->getInput('configFavicon'),
|
||||
'faviconDark' => $this->getInput('configFaviconDark'),
|
||||
'social' => [
|
||||
'facebookId' => $this->getInput('configSocialFacebookId'),
|
||||
'linkedinId' => $this->getInput('configSocialLinkedinId'),
|
||||
'instagramId' => $this->getInput('configSocialInstagramId'),
|
||||
'pinterestId' => $this->getInput('configSocialPinterestId'),
|
||||
'twitterId' => $this->getInput('configSocialTwitterId'),
|
||||
'youtubeId' => $this->getInput('configSocialYoutubeId'),
|
||||
'youtubeUserId' => $this->getInput('configSocialYoutubeUserId'),
|
||||
'githubId' => $this->getInput('configSocialGithubId')
|
||||
],
|
||||
'timezone' => $this->getInput('configTimezone', helper::FILTER_STRING_SHORT, true),
|
||||
'itemsperPage' => $this->getInput('configItemsperPage', helper::FILTER_INT,true),
|
||||
'legalPageId' => $legalPageId,
|
||||
'searchPageId' => $searchPageId,
|
||||
'metaDescription' => $this->getInput('configMetaDescription', helper::FILTER_STRING_LONG, true),
|
||||
'title' => $this->getInput('configTitle', 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),
|
||||
'title' => $this->getInput('configTitle', helper::FILTER_STRING_SHORT, true)
|
||||
]
|
||||
]);
|
||||
// Générer robots.txt et sitemap
|
||||
$this->generateFiles();
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl(),
|
||||
'notification' => 'Modifications enregistrées',
|
||||
'state' => $success
|
||||
]);
|
||||
}
|
||||
// Initialisation du screen - APPEL AUTO DESACTIVE POUR EVITER UN RALENTISSEMENT
|
||||
/*
|
||||
if (!file_exists(self::FILE_DIR.'source/screenshot.jpg')) {
|
||||
$this->configMetaImage();
|
||||
}
|
||||
*/
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'title' => 'Configuration',
|
||||
'view' => 'index'
|
||||
]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Configuration avancée
|
||||
*/
|
||||
public function advanced() {
|
||||
// Soumission du formulaire
|
||||
if($this->isPost()) {
|
||||
$success = true;
|
||||
// Basculement en mise à jour auto
|
||||
// Remise à 0 du compteur
|
||||
if ($this->getData(['config','autoUpdate']) === false &&
|
||||
$this->getInput('configAdvancedAutoUpdate', helper::FILTER_BOOLEAN) === true) {
|
||||
$this->setData(['core','lastAutoUpdate',0]);
|
||||
}
|
||||
// Sauvegarder
|
||||
$this->setData([
|
||||
'config',
|
||||
[
|
||||
'analyticsId' => $this->getInput('configAdvancedAnalyticsId'),
|
||||
'autoBackup' => $this->getInput('configAdvancedAutoBackup', helper::FILTER_BOOLEAN),
|
||||
'maintenance' => $this->getInput('configAdvancedMaintenance', helper::FILTER_BOOLEAN),
|
||||
'cookieConsent' => $this->getInput('configAdvancedCookieConsent', helper::FILTER_BOOLEAN),
|
||||
'favicon' => $this->getInput('configAdvancedFavicon'),
|
||||
'faviconDark' => $this->getInput('configAdvancedFaviconDark'),
|
||||
'social' => [
|
||||
'facebookId' => $this->getInput('configAdvancedSocialFacebookId'),
|
||||
'linkedinId' => $this->getInput('configAdvancedSocialLinkedinId'),
|
||||
'instagramId' => $this->getInput('configAdvancedSocialInstagramId'),
|
||||
'pinterestId' => $this->getInput('configAdvancedSocialPinterestId'),
|
||||
'twitterId' => $this->getInput('configAdvancedSocialTwitterId'),
|
||||
'youtubeId' => $this->getInput('configAdvancedSocialYoutubeId'),
|
||||
'youtubeUserId' => $this->getInput('configAdvancedSocialYoutubeUserId'),
|
||||
'githubId' => $this->getInput('configAdvancedSocialGithubId')
|
||||
],
|
||||
'timezone' => $this->getInput('configAdvancedTimezone', helper::FILTER_STRING_SHORT, true),
|
||||
'itemsperPage' => $this->getInput('configAdvancedItemsperPage', helper::FILTER_INT,true),
|
||||
'autoUpdate' => $this->getInput('configAdvancedAutoUpdate', helper::FILTER_BOOLEAN),
|
||||
'autoUpdateHtaccess' => $this->getInput('configAdvancedAutoUpdateHtaccess', helper::FILTER_BOOLEAN),
|
||||
'proxyType' => $this->getInput('configAdvancedProxyType'),
|
||||
'proxyUrl' => $this->getInput('configAdvancedProxyUrl'),
|
||||
'proxyPort' => $this->getInput('configAdvancedProxyPort',helper::FILTER_INT),
|
||||
'captchaStrong' => $this->getInput('configAdvancedCaptchaStrong',helper::FILTER_BOOLEAN),
|
||||
'smtp' => [
|
||||
'enable' => $this->getInput('configSmtpEnable',helper::FILTER_BOOLEAN),
|
||||
'host' => $this->getInput('configSmtpHost',helper::FILTER_STRING_SHORT),
|
||||
'port' => $this->getInput('configSmtpPort',helper::FILTER_INT),
|
||||
'auth' => $this->getInput('configSmtpAuth',helper::FILTER_BOOLEAN),
|
||||
'secure' => $this->getInput('configSmtpSecure'),
|
||||
'username' => $this->getInput('configSmtpUsername',helper::FILTER_STRING_SHORT),
|
||||
'password' =>helper::encrypt($this->getData(['config','smtp','username']),$this->getInput('configSmtpPassword')),
|
||||
'sender' => $this->getInput('configSmtpSender',helper::FILTER_MAIL)
|
||||
'enable' => $this->getInput('configAdvancedSmtpEnable',helper::FILTER_BOOLEAN),
|
||||
'host' => $this->getInput('configAdvancedSmtpHost',helper::FILTER_STRING_SHORT),
|
||||
'port' => $this->getInput('configAdvancedSmtpPort',helper::FILTER_INT),
|
||||
'auth' => $this->getInput('configAdvancedSmtpAuth',helper::FILTER_BOOLEAN),
|
||||
'secure' => $this->getInput('configAdvancedSmtpSecure'),
|
||||
'username' => $this->getInput('configAdvancedSmtpUsername',helper::FILTER_STRING_SHORT),
|
||||
'password' =>helper::encrypt($this->getData(['config','smtp','username']),$this->getInput('configAdvancedSmtpPassword')),
|
||||
'sender' => $this->getInput('configAdvancedSmtpSender',helper::FILTER_MAIL)
|
||||
],
|
||||
'connect' => [
|
||||
'attempt' => $this->getInput('configConnectAttempt',helper::FILTER_INT),
|
||||
'timeout' => $this->getInput('configConnectTimeout',helper::FILTER_INT),
|
||||
'log' => $this->getInput('configConnectLog',helper::FILTER_BOOLEAN),
|
||||
'captcha' => $this->getInput('configConnectCaptcha',helper::FILTER_BOOLEAN),
|
||||
'attempt' => $this->getInput('configAdvancedConnectAttempt',helper::FILTER_INT),
|
||||
'timeout' => $this->getInput('configAdvancedConnectTimeout',helper::FILTER_INT),
|
||||
'log' => $this->getInput('configAdvancedConnectLog',helper::FILTER_BOOLEAN),
|
||||
'captcha' => $this->getInput('configAdvancedConnectCaptcha',helper::FILTER_BOOLEAN),
|
||||
]
|
||||
]
|
||||
]);
|
||||
|
||||
// Efface les fichiers de backup lorsque l'option est désactivée
|
||||
if ($this->getInput('configAdvancedFileBackup', helper::FILTER_BOOLEAN) === false) {
|
||||
$path = realpath('site/data');
|
||||
foreach (new RecursiveIteratorIterator(new RecursiveDirectoryIterator($path)) as $filename)
|
||||
{
|
||||
if (strpos($filename,'backup.json')) {
|
||||
unlink($filename);
|
||||
}
|
||||
}
|
||||
if (file_exists('site/data/.backup')) unlink('site/data/.backup');
|
||||
} else {
|
||||
touch('site/data/.backup');
|
||||
}
|
||||
// Notice
|
||||
if(self::$inputNotices === []) {
|
||||
// Active la réécriture d'URL
|
||||
$rewrite = $this->getInput('rewrite', helper::FILTER_BOOLEAN);
|
||||
@ -536,16 +585,10 @@ class config extends common {
|
||||
'state' => $success
|
||||
]);
|
||||
}
|
||||
// Initialisation du screen - APPEL AUTO DESACTIVE POUR EVITER UN RALENTISSEMENT
|
||||
/*
|
||||
if (!file_exists(self::FILE_DIR.'source/screenshot.jpg')) {
|
||||
$this->configMetaImage();
|
||||
}
|
||||
*/
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'title' => 'Configuration',
|
||||
'view' => 'index'
|
||||
'title' => 'Configuration avancée',
|
||||
'view' => 'advanced'
|
||||
]);
|
||||
}
|
||||
|
||||
@ -638,14 +681,14 @@ class config extends common {
|
||||
file_put_contents(self::DATA_DIR . 'journal.log',$d);
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
'redirect' => helper::baseUrl() . 'config/advanced',
|
||||
'notification' => 'Journal réinitialisé avec succès',
|
||||
'state' => true
|
||||
]);
|
||||
} else {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
'redirect' => helper::baseUrl() . 'config/advanced',
|
||||
'notification' => 'Aucun journal à effacer',
|
||||
'state' => false
|
||||
]);
|
||||
@ -677,7 +720,7 @@ class config extends common {
|
||||
} else {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
'redirect' => helper::baseUrl() . 'config/advanced',
|
||||
'notification' => 'Aucun fichier journal à télécharger',
|
||||
'state' => false
|
||||
]);
|
||||
@ -718,7 +761,7 @@ class config extends common {
|
||||
} else {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
'redirect' => helper::baseUrl() . 'config/advanced',
|
||||
'notification' => 'Aucune liste noire à télécharger',
|
||||
'state' => false
|
||||
]);
|
||||
@ -731,17 +774,17 @@ class config extends common {
|
||||
|
||||
public function blacklistReset() {
|
||||
if ( file_exists(self::DATA_DIR . 'blacklist.json') ) {
|
||||
unlink(self::DATA_DIR . 'blacklist.json');
|
||||
$this->setData(['blacklist',[]]);
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
'redirect' => helper::baseUrl() . 'config/advanced',
|
||||
'notification' => 'Liste noire réinitialisée avec succès',
|
||||
'state' => true
|
||||
]);
|
||||
} else {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
'redirect' => helper::baseUrl() . 'config/advanced',
|
||||
'notification' => 'Pas de liste à effacer',
|
||||
'state' => false
|
||||
]);
|
||||
|
37
core/module/config/view/advanced/advanced.css
Normal file
@ -0,0 +1,37 @@
|
||||
/**
|
||||
* This file is part of Zwii.
|
||||
*
|
||||
* For full copyright and license information, please see the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*
|
||||
* @author Rémi Jean <remi.jean@outlook.com>
|
||||
* @copyright Copyright (C) 2008-2018, Rémi Jean
|
||||
* @author Frédéric Tempez <frederic.tempez@outlook.com>
|
||||
* @copyright Copyright (C) 2018-2020, Frédéric Tempez
|
||||
* @license GNU General Public License, version 3
|
||||
* @link http://zwiicms.fr/
|
||||
*/
|
||||
|
||||
|
||||
/** NE PAS EFFACER
|
||||
* admin.css
|
||||
*/
|
||||
|
||||
.blockContainer {
|
||||
display : none;
|
||||
}
|
||||
|
||||
#info .zwiico-plus-circled {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.zwiico-minus-circled,
|
||||
#info .zwiico-minus-circled {
|
||||
display: none;
|
||||
}
|
||||
|
||||
|
||||
.zwiico-minus-circled,
|
||||
.zwiico-plus-circled {
|
||||
cursor: pointer;
|
||||
}
|
0
core/module/config/view/index/index.js.php → core/module/config/view/advanced/advanced.js.php
Executable file → Normal file
507
core/module/config/view/advanced/advanced.php
Normal file
@ -0,0 +1,507 @@
|
||||
<?php echo template::formOpen('configAdvancedForm'); ?>
|
||||
<div class="row">
|
||||
<div class="col2">
|
||||
<?php echo template::button('configAdvancedBack', [
|
||||
'class' => 'buttonGrey',
|
||||
'href' => helper::baseUrl() . 'config',
|
||||
'ico' => 'left',
|
||||
'value' => 'Retour'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2 offset8">
|
||||
<?php echo template::submit('configAdvancedSubmit'); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Maintenance</h4>
|
||||
<div class="col3">
|
||||
<?php echo template::checkbox('configAdvancedMaintenance', true, 'Site en maintenance', [
|
||||
'checked' => $this->getData(['config', 'maintenance'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 offset1">
|
||||
<?php echo template::button('configManageButton', [
|
||||
'href' => helper::baseUrl() . 'config/backup',
|
||||
'value' => 'Sauvegarder',
|
||||
'ico' => 'download'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 offset1">
|
||||
<?php echo template::button('configManageButton', [
|
||||
'href' => helper::baseUrl() . 'config/manage',
|
||||
'value' => 'Restaurer',
|
||||
'ico' => 'upload'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Réglages</h4>
|
||||
<?php $error = helper::urlGetContents('http://zwiicms.fr/update/' . common::ZWII_UPDATE_CHANNEL . '/version');?>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::file('configAdvancedFavicon', [
|
||||
'type' => 1,
|
||||
'help' => 'Pensez à supprimer le cache de votre navigateur si la favicon ne change pas.',
|
||||
'label' => 'Favicon',
|
||||
'value' => $this->getData(['config', 'favicon'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::file('configAdvancedFaviconDark', [
|
||||
'type' => 1,
|
||||
'help' => 'Sélectionnez une icône adaptée à un thème sombre.<br>Pensez à supprimer le cache de votre navigateur si la favicon ne change pas.',
|
||||
'label' => 'Favicon thème sombre',
|
||||
'value' => $this->getData(['config', 'faviconDark'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::select('configAdvancedItemsperPage', $module::$ItemsList, [
|
||||
'label' => 'Articles par page',
|
||||
'selected' => $this->getData(['config', 'itemsperPage']),
|
||||
'help' => 'Modules Blog et News'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::select('configAdvancedTimezone', $module::$timezones, [
|
||||
'label' => 'Fuseau horaire',
|
||||
'selected' => $this->getData(['config', 'timezone']),
|
||||
'help' => 'Le fuseau horaire est utile au bon référencement'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 verticalAlignBottom">
|
||||
<?php echo template::checkbox('configAdvancedCookieConsent', true, 'Consentement aux cookies', [
|
||||
'checked' => $this->getData(['config', 'cookieConsent'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 verticalAlignBottom">
|
||||
<?php echo template::checkbox('configAdvancedCaptchaStrong', true, 'Captcha renforcé', [
|
||||
'checked' => $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 renforcé utilise quatre opérations de nombres de 0 à 20.'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('rewrite', true, 'Réécriture d\'URL', [
|
||||
'checked' => helper::checkRewrite(),
|
||||
'help' => 'Vérifiez d\'abord que votre serveur l\'autorise : ce n\'est pas le cas chez Free.'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('configAdvancedAutoBackup', true, 'Sauvegarde quotidienne', [
|
||||
'checked' => $this->getData(['config', 'autoBackup']),
|
||||
'help' => '<p>Une archive contenant le dossier /site/data est copiée dans le dossier \'site/backup\'. La sauvegarde est conservée pendant 30 jours.</p><p>Les fichiers du site ne sont pas sauvegardés automatiquement.</p>'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('configAdvancedFileBackup', true, 'Copie de sauvegarde', [
|
||||
'checked' => file_exists('site/data/.backup'),
|
||||
'help' => '<p>Un fichier .backup.json est généré à chaque édition ou effacement d\'une donnée. La désactivation entraîne la suppression de ces fichiers.</p>'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('configAdvancedAutoUpdate', true, 'Mise à jour en ligne', [
|
||||
'checked' => $this->getData(['config', 'autoUpdate']),
|
||||
'help' => 'Vérifie une fois par jour l\'existence d\'une mise à jour.',
|
||||
'disabled' => !$error
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 ">
|
||||
<?php echo template::checkbox('configAdvancedAutoUpdateHtaccess', true, 'Préserver htaccess', [
|
||||
'checked' => $this->getData(['config', 'autoUpdateHtaccess']),
|
||||
'help' => 'Lors d\'une mise à jour automatique, conserve le fichier htaccess de la racine du site.',
|
||||
'disabled' => !$error
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 ">
|
||||
<?php echo template::button('configAdvancedUpdateForced', [
|
||||
'ico' => 'download-cloud',
|
||||
'href' => helper::baseUrl() . 'install/update',
|
||||
'value' => 'Mise à jour manuelle',
|
||||
'class' => 'buttonRed',
|
||||
'disabled' => !$error
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="social">
|
||||
<h4>Réseaux sociaux
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col3">
|
||||
<?php echo template::text('configAdvancedSocialFacebookId', [
|
||||
'help' => 'Saisissez votre ID : https://www.facebook.com/[ID].',
|
||||
'label' => 'Facebook',
|
||||
'value' => $this->getData(['config', 'social', 'facebookId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configAdvancedSocialInstagramId', [
|
||||
'help' => 'Saisissez votre ID : https://www.instagram.com/[ID].',
|
||||
'label' => 'Instagram',
|
||||
'value' => $this->getData(['config', 'social', 'instagramId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configAdvancedSocialYoutubeId', [
|
||||
'help' => 'ID de la chaîne : https://www.youtube.com/channel/[ID].',
|
||||
'label' => 'Chaîne Youtube',
|
||||
'value' => $this->getData(['config', 'social', 'youtubeId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configAdvancedSocialYoutubeUserId', [
|
||||
'help' => 'Saisissez votre ID Utilisateur : https://www.youtube.com/user/[ID].',
|
||||
'label' => 'Youtube',
|
||||
'value' => $this->getData(['config', 'social', 'youtubeUserId'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col3">
|
||||
<?php echo template::text('configAdvancedSocialTwitterId', [
|
||||
'help' => 'Saisissez votre ID : https://twitter.com/[ID].',
|
||||
'label' => 'Twitter',
|
||||
'value' => $this->getData(['config', 'social', 'twitterId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configAdvancedSocialPinterestId', [
|
||||
'help' => 'Saisissez votre ID : https://pinterest.com/[ID].',
|
||||
'label' => 'Pinterest',
|
||||
'value' => $this->getData(['config', 'social', 'pinterestId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configAdvancedSocialLinkedinId', [
|
||||
'help' => 'Saisissez votre ID Linkedin : https://fr.linkedin.com/in/[ID].',
|
||||
'label' => 'Linkedin',
|
||||
'value' => $this->getData(['config', 'social', 'linkedinId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configAdvancedSocialGithubId', [
|
||||
'help' => 'Saisissez votre ID Github : https://github.com/[ID].',
|
||||
'label' => 'Github',
|
||||
'value' => $this->getData(['config', 'social', 'githubId'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="ceo">
|
||||
<h4>Référencement
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col4 offset1">
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<?php echo template::button('configAdvancedMetaImage', [
|
||||
'href' => helper::baseUrl() . 'config/configMetaImage',
|
||||
'value' => 'Capture Open Graph',
|
||||
'ico' => 'pencil'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<?php echo template::button('configAdvancedSiteMap', [
|
||||
'href' => helper::baseUrl() . 'config/generateFiles',
|
||||
'value' => 'Sitemap.xml / Robots.txt',
|
||||
'ico' => 'pencil'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col6 offset1">
|
||||
<?php if (file_exists(self::FILE_DIR.'source/screenshot.jpg')): ?>
|
||||
<div class="row">
|
||||
<div class="col8 offset2 textAlignCenter">
|
||||
<img src="<?php echo helper::baseUrl(false) . self::FILE_DIR.'source/screenshot.jpg';?>" data-tippy-content="Cette capture d'écran est nécessaire aux partages sur les réseaux sociaux. Elle est régénérée lorsque le fichier 'screenshot.jpg' est effacé du gestionnaire de fichiers." />
|
||||
</div>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="login">
|
||||
<h4>Sécurité de la connexion
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col3">
|
||||
<?php echo template::select('configAdvancedConnectAttempt', $module::$connectAttempt , [
|
||||
'label' => 'Connexions successives',
|
||||
'selected' => $this->getData(['config', 'connect', 'attempt'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::select('configAdvancedConnectTimeout', $module::$connectTimeout , [
|
||||
'label' => 'Blocage après échecs',
|
||||
'selected' => $this->getData(['config', 'connect', 'timeout'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 verticalAlignBottom">
|
||||
<label id="helpBlacklist">Comptes inexistants
|
||||
<?php echo template::help(
|
||||
'La liste noire énumère les tentatives de connexion à partir de comptes inexistants. Sont stockés : la date, l\'heure, le nom du compte et l\'IP.
|
||||
Après le nombre de tentatives autorisées, l\'IP et le compte sont bloqués.');
|
||||
?>
|
||||
</label>
|
||||
<?php echo template::button('configAdvancedConnectblacListDownload', [
|
||||
'href' => helper::baseUrl() . 'config/blacklistDownload',
|
||||
'value' => 'Télécharger liste noire',
|
||||
'ico' => 'download'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 verticalAlignBottom">
|
||||
<?php echo template::button('configAdvancedConnectReset', [
|
||||
'class' => 'buttonRed',
|
||||
'href' => helper::baseUrl() . 'config/blacklistReset',
|
||||
'value' => 'Réinitialiser liste',
|
||||
'ico' => 'cancel'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col3">
|
||||
<?php echo template::checkbox('configAdvancedConnectCaptcha', true, 'Captcha à la connexion', [
|
||||
'checked' => $this->getData(['config', 'connect','captcha'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="logs">
|
||||
<h4>Journalisation
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col4 verticalAlignBottom">
|
||||
<?php echo template::checkbox('configAdvancedConnectLog', true, 'Activer la journalisation', [
|
||||
'checked' => $this->getData(['config', 'connect', 'log'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 offset2">
|
||||
<?php echo template::button('configAdvancedLogDownload', [
|
||||
'href' => helper::baseUrl() . 'config/logDownload',
|
||||
'value' => 'Télécharger journal',
|
||||
'ico' => 'download'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::button('configAdvancedLogReset', [
|
||||
'class' => 'buttonRed',
|
||||
'href' => helper::baseUrl() . 'config/logReset',
|
||||
'value' => 'Réinitialiser journal',
|
||||
'ico' => 'cancel'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="network">
|
||||
<h4>Réseau
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col2">
|
||||
<?php echo template::select('configAdvancedProxyType', $module::$proxyType, [
|
||||
'label' => 'Type de proxy',
|
||||
'selected' => $this->getData(['config', 'proxyType'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col8">
|
||||
<?php echo template::text('configAdvancedProxyUrl', [
|
||||
'label' => 'Adresse du proxy',
|
||||
'placeholder' => 'cache.proxy.fr',
|
||||
'value' => $this->getData(['config', 'proxyUrl'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::text('configAdvancedProxyPort', [
|
||||
'label' => 'Port du proxy',
|
||||
'placeholder' => '6060',
|
||||
'value' => $this->getData(['config', 'proxyPort'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="smtp">
|
||||
<h4>Messagerie SMTP
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('configAdvancedSmtpEnable', true, 'Activer SMTP', [
|
||||
'checked' => $this->getData(['config', 'smtp','enable']),
|
||||
'help' => 'Paramètres à utiliser lorsque votre hébergeur ne propose pas la fonctionnalité d\'envoi de mail.'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div id="configSmtpParam">
|
||||
<div class="row">
|
||||
<div class="col8">
|
||||
<?php echo template::text('configAdvancedSmtpHost', [
|
||||
'label' => 'Adresse SMTP',
|
||||
'placeholder' => 'smtp.fr',
|
||||
'value' => $this->getData(['config', 'smtp','host'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::text('configAdvancedSmtpPort', [
|
||||
'label' => 'Port SMTP',
|
||||
'placeholder' => '589',
|
||||
'value' => $this->getData(['config', 'smtp','port'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::select('configAdvancedSmtpAuth', $module::$SMTPauth, [
|
||||
'label' => 'Authentification',
|
||||
'selected' => $this->getData(['config', 'smtp','auth'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div id="configSmtpAuthParam">
|
||||
<div class="row">
|
||||
<div class="col5">
|
||||
<?php echo template::text('configAdvancedSmtpUsername', [
|
||||
'label' => 'Nom utilisateur',
|
||||
'value' => $this->getData(['config', 'smtp','username' ])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col5">
|
||||
<?php echo template::password('configAdvancedSmtpPassword', [
|
||||
'label' => 'Mot de passe',
|
||||
'autocomplete' => 'off',
|
||||
'value' => $this->getData(['config', 'smtp','username' ]) ? helper::decrypt ($this->getData(['config', 'smtp','username' ]),$this->getData(['config','smtp','password'])) : ''
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::select('configAdvancedSmtpSecure', $module::$SMTPEnc , [
|
||||
'label' => 'Sécurité',
|
||||
'selected' => $this->getData(['config', 'smtp','secure'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="script">
|
||||
<h4>Scripts
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col3">
|
||||
<?php echo template::text('configAdvancedAnalyticsId', [
|
||||
'help' => 'Saisissez l\'ID de suivi.',
|
||||
'label' => 'Google Analytics',
|
||||
'placeholder' => 'UA-XXXXXXXX-X',
|
||||
'value' => $this->getData(['config', 'analyticsId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 offset3 verticalAlignBottom">
|
||||
<?php echo template::button('configAdvancedScriptHead', [
|
||||
'href' => helper::baseUrl() . 'config/script/head',
|
||||
'value' => 'Script dans head',
|
||||
'ico' => 'pencil'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 verticalAlignBottom">
|
||||
<?php echo template::button('configAdvancedScriptBody', [
|
||||
'href' => helper::baseUrl() . 'config/script/body',
|
||||
'value' => 'Script dans body',
|
||||
'ico' => 'pencil'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php echo template::formClose(); ?>
|
@ -12,7 +12,6 @@
|
||||
* @link http://zwiicms.fr/
|
||||
*/
|
||||
|
||||
|
||||
/** NE PAS EFFACER
|
||||
* admin.css
|
||||
*/
|
||||
|
@ -3,7 +3,7 @@
|
||||
<div class="col2">
|
||||
<?php echo template::button('configBackupBack', [
|
||||
'class' => 'buttonGrey',
|
||||
'href' => helper::baseUrl() . 'config',
|
||||
'href' => helper::baseUrl() . 'config/advanced',
|
||||
'ico' => 'left',
|
||||
'value' => 'Retour'
|
||||
]); ?>
|
||||
|
@ -16,22 +16,3 @@
|
||||
/** NE PAS EFFACER
|
||||
* admin.css
|
||||
*/
|
||||
|
||||
.blockContainer {
|
||||
display : none;
|
||||
}
|
||||
|
||||
#info .zwiico-plus-circled {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.zwiico-minus-circled,
|
||||
#info .zwiico-minus-circled {
|
||||
display: none;
|
||||
}
|
||||
|
||||
|
||||
.zwiico-minus-circled,
|
||||
.zwiico-plus-circled {
|
||||
cursor: pointer;
|
||||
}
|
@ -8,16 +8,11 @@
|
||||
'value' => 'Accueil'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2 offset4">
|
||||
<?php echo template::button('configManageButton', [
|
||||
'href' => helper::baseUrl() . 'config/backup',
|
||||
'value' => 'Sauvegarder'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::button('configManageButton', [
|
||||
'href' => helper::baseUrl() . 'config/manage',
|
||||
'value' => 'Restaurer'
|
||||
<div class="col2 offset6">
|
||||
<?php echo template::button('configAdvancedButton', [
|
||||
'href' => helper::baseUrl() . 'config/advanced',
|
||||
'value' => 'Avancée',
|
||||
'ico' => 'cog-alt',
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
@ -27,12 +22,12 @@
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Informations générales</h4>
|
||||
<h4>Identité</h4>
|
||||
<div class="row">
|
||||
<div class="col9">
|
||||
<?php echo template::text('configTitle', [
|
||||
'label' => 'Titre du site',
|
||||
'value' => $this->getData(['config', 'title']),
|
||||
'value' => $this->getData(['locale', 'title']),
|
||||
'help' => 'Il apparaît dans la barre de titre et les partages sur les réseaux sociaux.'
|
||||
]); ?>
|
||||
</div>
|
||||
@ -48,105 +43,8 @@
|
||||
<div class="col12">
|
||||
<?php echo template::textarea('configMetaDescription', [
|
||||
'label' => 'Description du site',
|
||||
'value' => $this->getData(['config', 'metaDescription']),
|
||||
'help' => 'La description participe au référencement, n\'oubliez pas de personnaliser la description de chaque page sans un copié collé.'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Paramètres généraux</h4>
|
||||
<?php $error = helper::urlGetContents('http://zwiicms.fr/update/' . common::ZWII_UPDATE_CHANNEL . '/version');?>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::file('configFavicon', [
|
||||
'type' => 1,
|
||||
'help' => 'Pensez à supprimer le cache de votre navigateur si la favicon ne change pas.',
|
||||
'label' => 'Favicon',
|
||||
'value' => $this->getData(['config', 'favicon'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::file('configFaviconDark', [
|
||||
'type' => 1,
|
||||
'help' => 'Sélectionnez une icône adaptée à un thème sombre.<br>Pensez à supprimer le cache de votre navigateur si la favicon ne change pas.',
|
||||
'label' => 'Favicon thème sombre',
|
||||
'value' => $this->getData(['config', 'faviconDark'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::select('configItemsperPage', $module::$ItemsList, [
|
||||
'label' => 'Articles par page',
|
||||
'selected' => $this->getData(['config', 'itemsperPage']),
|
||||
'help' => 'Modules Blog et News'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::select('configTimezone', $module::$timezones, [
|
||||
'label' => 'Fuseau horaire',
|
||||
'selected' => $this->getData(['config', 'timezone']),
|
||||
'help' => 'Le fuseau horaire est utile au bon référencement'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 verticalAlignBottom">
|
||||
<?php echo template::checkbox('configCookieConsent', true, 'Consentement aux cookies', [
|
||||
'checked' => $this->getData(['config', 'cookieConsent'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 verticalAlignBottom">
|
||||
<?php echo template::checkbox('configCaptchaStrong', true, 'Captcha renforcé', [
|
||||
'checked' => $this->getData(['config','captchaStrong']),
|
||||
'help' => 'Option recommandée pour sécuriser la connexion. S\'applique à tous les captchas du site.'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('rewrite', true, 'Réécriture d\'URL', [
|
||||
'checked' => helper::checkRewrite(),
|
||||
'help' => 'Vérifiez d\'abord que votre serveur l\'autorise : ce n\'est pas le cas chez Free.'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('configMaintenance', true, 'Site en maintenance', [
|
||||
'checked' => $this->getData(['config', 'maintenance'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('configAutoBackup', true, 'Sauvegarde quotidienne', [
|
||||
'checked' => $this->getData(['config', 'autoBackup']),
|
||||
'help' => '<p>Une archive contenant le dossier /site/data est copiée dans le dossier \'site/backup\'. La sauvegarde est conservée pendant 30 jours.</p><p>Les fichiers du site ne sont pas sauvegardés automatiquement.</p>'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('configAutoUpdate', true, 'Mise à jour en ligne', [
|
||||
'checked' => $this->getData(['config', 'autoUpdate']),
|
||||
'help' => 'Vérifie une fois par jour l\'existence d\'une mise à jour.',
|
||||
'disabled' => !$error
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 ">
|
||||
<?php echo template::checkbox('configAutoUpdateHtaccess', true, 'Préserver htaccess', [
|
||||
'checked' => $this->getData(['config', 'autoUpdateHtaccess']),
|
||||
'help' => 'Lors d\'une mise à jour automatique, conserve le fichier htaccess de la racine du site.',
|
||||
'disabled' => !$error
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 ">
|
||||
<?php echo template::button('configUpdateForced', [
|
||||
'ico' => 'download-cloud',
|
||||
'href' => helper::baseUrl() . 'install/update',
|
||||
'value' => 'Mise à jour manuelle',
|
||||
'class' => 'buttonRed',
|
||||
'disabled' => !$error
|
||||
'value' => $this->getData(['locale', 'metaDescription']),
|
||||
'help' => 'La description d\'une page participe à son référencement, chaque page doit disposer d\'une description différente.'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
@ -177,21 +75,21 @@
|
||||
}
|
||||
echo template::select('configHomePageId', helper::arrayCollumn($pages, 'title', 'SORT_ASC'), [
|
||||
'label' => 'Accueil du site',
|
||||
'selected' =>$this->getData(['config', 'homePageId']),
|
||||
'selected' =>$this->getData(['locale', 'homePageId']),
|
||||
'help' => 'La première page que vos visiteurs verront.'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::select('configLegalPageId', array_merge(['none' => 'Aucune'] , helper::arrayCollumn($pages, 'title', 'SORT_ASC') ) , [
|
||||
'label' => 'Mentions légales',
|
||||
'selected' => $this->getData(['config', 'legalPageId']),
|
||||
'selected' => $this->getData(['locale', 'legalPageId']),
|
||||
'help' => 'Les mentions légales sont obligatoires en France. Une option du pied de page ajoute un lien discret vers cette page.'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::select('configSearchPageId', array_merge(['none' => 'Aucune'] , helper::arrayCollumn($pages, 'title', 'SORT_ASC') ) , [
|
||||
'label' => 'Recherche dans le site',
|
||||
'selected' => $this->getData(['config', 'searchPageId']),
|
||||
'selected' => $this->getData(['locale', 'searchPageId']),
|
||||
'help' => 'Sélectionner la page "Recherche" ou une page contenant le module "Recherche" permet d\'activer un lien dans le pied de page. '
|
||||
]); ?>
|
||||
</div>
|
||||
@ -201,7 +99,7 @@
|
||||
<?php
|
||||
echo template::select('configPage403', array_merge(['none' => 'Page par défaut'],helper::arrayCollumn($orphans, 'title', 'SORT_ASC')), [
|
||||
'label' => 'Accès interdit, erreur 403',
|
||||
'selected' =>$this->getData(['config', 'page403']),
|
||||
'selected' =>$this->getData(['locale', 'page403']),
|
||||
'help' => 'Cette page ne doit pas apparaître dans l\'arborescence du menu. Créez une page orpheline.'
|
||||
]); ?>
|
||||
</div>
|
||||
@ -209,7 +107,7 @@
|
||||
<?php
|
||||
echo template::select('configPage404', array_merge(['none' => 'Page par défaut'],helper::arrayCollumn($orphans, 'title', 'SORT_ASC')), [
|
||||
'label' => 'Page inexistante, erreur 404',
|
||||
'selected' =>$this->getData(['config', 'page404']),
|
||||
'selected' =>$this->getData(['locale', 'page404']),
|
||||
'help' => 'Cette page ne doit pas apparaître dans l\'arborescence du menu. Créez une page orpheline.'
|
||||
]); ?>
|
||||
</div>
|
||||
@ -217,7 +115,7 @@
|
||||
<?php
|
||||
echo template::select('configPage302', array_merge(['none' => 'Page par défaut'],helper::arrayCollumn($orphans, 'title', 'SORT_ASC')), [
|
||||
'label' => 'Site en maintenance',
|
||||
'selected' =>$this->getData(['config', 'page302']),
|
||||
'selected' =>$this->getData(['locale', 'page302']),
|
||||
'help' => 'Cette page ne doit pas apparaître dans l\'arborescence du menu. Créez une page orpheline.'
|
||||
]); ?>
|
||||
</div>
|
||||
@ -225,373 +123,4 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="social">
|
||||
<h4>Réseaux sociaux
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col3">
|
||||
<?php echo template::text('configSocialFacebookId', [
|
||||
'help' => 'Saisissez votre ID : https://www.facebook.com/[ID].',
|
||||
'label' => 'Facebook',
|
||||
'value' => $this->getData(['config', 'social', 'facebookId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configSocialInstagramId', [
|
||||
'help' => 'Saisissez votre ID : https://www.instagram.com/[ID].',
|
||||
'label' => 'Instagram',
|
||||
'value' => $this->getData(['config', 'social', 'instagramId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configSocialYoutubeId', [
|
||||
'help' => 'ID de la chaîne : https://www.youtube.com/channel/[ID].',
|
||||
'label' => 'Chaîne Youtube',
|
||||
'value' => $this->getData(['config', 'social', 'youtubeId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configSocialYoutubeUserId', [
|
||||
'help' => 'Saisissez votre ID Utilisateur : https://www.youtube.com/user/[ID].',
|
||||
'label' => 'Youtube',
|
||||
'value' => $this->getData(['config', 'social', 'youtubeUserId'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col3">
|
||||
<?php echo template::text('configSocialTwitterId', [
|
||||
'help' => 'Saisissez votre ID : https://twitter.com/[ID].',
|
||||
'label' => 'Twitter',
|
||||
'value' => $this->getData(['config', 'social', 'twitterId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configSocialPinterestId', [
|
||||
'help' => 'Saisissez votre ID : https://pinterest.com/[ID].',
|
||||
'label' => 'Pinterest',
|
||||
'value' => $this->getData(['config', 'social', 'pinterestId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configSocialLinkedinId', [
|
||||
'help' => 'Saisissez votre ID Linkedin : https://fr.linkedin.com/in/[ID].',
|
||||
'label' => 'Linkedin',
|
||||
'value' => $this->getData(['config', 'social', 'linkedinId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::text('configSocialGithubId', [
|
||||
'help' => 'Saisissez votre ID Github : https://github.com/[ID].',
|
||||
'label' => 'Github',
|
||||
'value' => $this->getData(['config', 'social', 'githubId'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="ceo">
|
||||
<h4>Référencement
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col4 offset1">
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<?php echo template::button('configMetaImage', [
|
||||
'href' => helper::baseUrl() . 'config/configMetaImage',
|
||||
'value' => 'Capture Open Graph',
|
||||
'ico' => 'pencil'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<?php echo template::button('configSiteMap', [
|
||||
'href' => helper::baseUrl() . 'config/generateFiles',
|
||||
'value' => 'Sitemap.xml / Robots.txt',
|
||||
'ico' => 'pencil'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col6 offset1">
|
||||
<?php if (file_exists(self::FILE_DIR.'source/screenshot.jpg')): ?>
|
||||
<div class="row">
|
||||
<div class="col8 offset2 textAlignCenter">
|
||||
<img src="<?php echo helper::baseUrl(false) . self::FILE_DIR.'source/screenshot.jpg';?>" data-tippy-content="Cette capture d'écran est nécessaire aux partages sur les réseaux sociaux. Elle est régénérée lorsque le fichier 'screenshot.jpg' est effacé du gestionnaire de fichiers." />
|
||||
</div>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="login">
|
||||
<h4>Sécurité de la connexion
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col3">
|
||||
<?php echo template::select('configConnectAttempt', $module::$connectAttempt , [
|
||||
'label' => 'Tentatives avant blocage',
|
||||
'selected' => $this->getData(['config', 'connect', 'attempt'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::select('configConnectTimeout', $module::$connectTimeout , [
|
||||
'label' => 'Durée du blocage',
|
||||
'selected' => $this->getData(['config', 'connect', 'timeout'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 verticalAlignBottom">
|
||||
<label id="helpBlacklist">Comptes inexistants
|
||||
<?php echo template::help(
|
||||
'La liste noire énumère les tentatives de connexion à partir de comptes inexistants. Sont stockés : la date, l\'heure, le nom du compte et l\'IP.
|
||||
Après le nombre de tentatives autorisées, l\'IP et le compte sont bloqués.');
|
||||
?>
|
||||
</label>
|
||||
<?php echo template::button('configConnectblacListDownload', [
|
||||
'href' => helper::baseUrl() . 'config/blacklistDownload',
|
||||
'value' => 'Télécharger liste noire',
|
||||
'ico' => 'download'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 verticalAlignBottom">
|
||||
<?php echo template::button('ConfigConnectReset', [
|
||||
'class' => 'buttonRed',
|
||||
'href' => helper::baseUrl() . 'config/blacklistReset',
|
||||
'value' => 'Réinitialiser liste',
|
||||
'ico' => 'cancel'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col3">
|
||||
<?php echo template::checkbox('configConnectCaptcha', true, 'Captcha à la connexion', [
|
||||
'checked' => $this->getData(['config', 'connect','captcha'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="logs">
|
||||
<h4>Journalisation
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col4 verticalAlignBottom">
|
||||
<?php echo template::checkbox('configConnectLog', true, 'Activer la journalisation', [
|
||||
'checked' => $this->getData(['config', 'connect', 'log'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 offset2">
|
||||
<?php echo template::button('ConfigLogDownload', [
|
||||
'href' => helper::baseUrl() . 'config/logDownload',
|
||||
'value' => 'Télécharger journal',
|
||||
'ico' => 'download'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3">
|
||||
<?php echo template::button('ConfigLogReset', [
|
||||
'class' => 'buttonRed',
|
||||
'href' => helper::baseUrl() . 'config/logReset',
|
||||
'value' => 'Réinitialiser journal',
|
||||
'ico' => 'cancel'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="network">
|
||||
<h4>Réseau
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col2">
|
||||
<?php echo template::select('configProxyType', $module::$proxyType, [
|
||||
'label' => 'Type de proxy',
|
||||
'selected' => $this->getData(['config', 'proxyType'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col8">
|
||||
<?php echo template::text('configProxyUrl', [
|
||||
'label' => 'Adresse du proxy',
|
||||
'placeholder' => 'cache.proxy.fr',
|
||||
'value' => $this->getData(['config', 'proxyUrl'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::text('configProxyPort', [
|
||||
'label' => 'Port du proxy',
|
||||
'placeholder' => '6060',
|
||||
'value' => $this->getData(['config', 'proxyPort'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="smtp">
|
||||
<h4>Messagerie SMTP
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('configSmtpEnable', true, 'Activer SMTP', [
|
||||
'checked' => $this->getData(['config', 'smtp','enable']),
|
||||
'help' => 'Paramètres à utiliser lorsque votre hébergeur ne propose pas la fonctionnalité d\'envoi de mail.'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div id="configSmtpParam">
|
||||
<div class="row">
|
||||
<div class="col8">
|
||||
<?php echo template::text('configSmtpHost', [
|
||||
'label' => 'Adresse SMTP',
|
||||
'placeholder' => 'smtp.fr',
|
||||
'value' => $this->getData(['config', 'smtp','host'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::text('configSmtpPort', [
|
||||
'label' => 'Port SMTP',
|
||||
'placeholder' => '589',
|
||||
'value' => $this->getData(['config', 'smtp','port'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::select('configSmtpAuth', $module::$SMTPauth, [
|
||||
'label' => 'Authentification',
|
||||
'selected' => $this->getData(['config', 'smtp','auth'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div id="configSmtpAuthParam">
|
||||
<div class="row">
|
||||
<div class="col5">
|
||||
<?php echo template::text('configSmtpUsername', [
|
||||
'label' => 'Nom utilisateur',
|
||||
'value' => $this->getData(['config', 'smtp','username' ])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col5">
|
||||
<?php echo template::password('configSmtpPassword', [
|
||||
'label' => 'Mot de passe',
|
||||
'autocomplete' => 'off',
|
||||
'value' => $this->getData(['config', 'smtp','username' ]) ? helper::decrypt ($this->getData(['config', 'smtp','username' ]),$this->getData(['config','smtp','password'])) : ''
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::select('configSmtpSecure', $module::$SMTPEnc , [
|
||||
'label' => 'Sécurité',
|
||||
'selected' => $this->getData(['config', 'smtp','secure'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block" id="script">
|
||||
<h4>Scripts
|
||||
<div class="openClose">
|
||||
<?php
|
||||
echo template::ico('plus-circled','right');
|
||||
echo template::ico('minus-circled','right');
|
||||
?>
|
||||
</div>
|
||||
</h4>
|
||||
<div class="blockContainer">
|
||||
<div class="row">
|
||||
<div class="col3">
|
||||
<?php echo template::text('configAnalyticsId', [
|
||||
'help' => 'Saisissez l\'ID de suivi.',
|
||||
'label' => 'Google Analytics',
|
||||
'placeholder' => 'UA-XXXXXXXX-X',
|
||||
'value' => $this->getData(['config', 'analyticsId'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 offset3 verticalAlignBottom">
|
||||
<?php echo template::button('configScriptHead', [
|
||||
'href' => helper::baseUrl() . 'config/script/head',
|
||||
'value' => 'Script dans head',
|
||||
'ico' => 'pencil'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 verticalAlignBottom">
|
||||
<?php echo template::button('ConfigScriptBody', [
|
||||
'href' => helper::baseUrl() . 'config/script/body',
|
||||
'value' => 'Script dans body',
|
||||
'ico' => 'pencil'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php echo template::formClose(); ?>
|
||||
|
@ -3,7 +3,7 @@
|
||||
<div class="col2">
|
||||
<?php echo template::button('configManageBack', [
|
||||
'class' => 'buttonGrey',
|
||||
'href' => helper::baseUrl() . 'config',
|
||||
'href' => helper::baseUrl() . 'config/advanced',
|
||||
'ico' => 'left',
|
||||
'value' => 'Retour'
|
||||
]); ?>
|
||||
|
@ -3,7 +3,7 @@
|
||||
<div class="col2">
|
||||
<?php echo template::button('configManageBack', [
|
||||
'class' => 'buttonGrey',
|
||||
'href' => helper::baseUrl() . 'config',
|
||||
'href' => helper::baseUrl() . 'config/advanced',
|
||||
'ico' => 'left',
|
||||
'value' => 'Retour'
|
||||
]); ?>
|
||||
|
@ -61,6 +61,8 @@ class install extends common {
|
||||
'forgot' => 0,
|
||||
'group' => self::GROUP_ADMIN,
|
||||
'lastname' => $userLastname,
|
||||
'pseudo' => 'Admin',
|
||||
'signature' => 1,
|
||||
'mail' => $userMail,
|
||||
'password' => $this->getInput('installPassword', helper::FILTER_PASSWORD, true)
|
||||
]
|
||||
|
@ -9,12 +9,6 @@ class init extends common {
|
||||
'cookieConsent' => true,
|
||||
'favicon' => 'favicon.ico',
|
||||
'faviconDark' => 'faviconDark.ico',
|
||||
'homePageId' => 'accueil',
|
||||
'page302' => 'erreur302',
|
||||
'page403' => 'erreur403',
|
||||
'page404' => 'erreur404',
|
||||
'legalPageId' => 'mentions-legales',
|
||||
'searchPageId' => 'recherche',
|
||||
'maintenance' => false,
|
||||
'captchaStrong' => false,
|
||||
'social' => [
|
||||
@ -28,8 +22,6 @@ class init extends common {
|
||||
],
|
||||
'timezone' => 'Europe/Paris',
|
||||
'itemsperPage' => 10,
|
||||
'metaDescription' => 'Zwii est un CMS sans base de données qui permet de créer et gérer facilement un site web sans aucune connaissance en programmation.',
|
||||
'title' => 'Votre site en quelques clics !',
|
||||
'proxyUrl' => '',
|
||||
'proxyPort' => '',
|
||||
'proxyType' => 'tcp://',
|
||||
@ -41,16 +33,26 @@ class init extends common {
|
||||
'attempt' => 3,
|
||||
'log' => false,
|
||||
'captcha' => true
|
||||
]
|
||||
],
|
||||
],
|
||||
'core' => [
|
||||
'dataVersion' => 10306,
|
||||
'dataVersion' => 10400,
|
||||
'lastBackup' => 0,
|
||||
'lastClearTmp' => 0,
|
||||
'lastAutoUpdate' => 0,
|
||||
'updateAvailable' => false,
|
||||
'baseUrl' => ''
|
||||
],
|
||||
'locale' => [
|
||||
'homePageId' => 'accueil',
|
||||
'page302' => 'none',
|
||||
'page403' => 'none',
|
||||
'page404' => 'none',
|
||||
'legalPageId' => 'none',
|
||||
'searchPageId' => 'none',
|
||||
'metaDescription' => 'Zwii est un CMS sans base de données qui permet de créer et gérer facilement un site web sans aucune connaissance en programmation.',
|
||||
'title' => 'Votre site en quelques clics !'
|
||||
],
|
||||
'page' => [
|
||||
'accueil' => [
|
||||
'typeMenu' => 'text',
|
||||
@ -199,6 +201,7 @@ class init extends common {
|
||||
'backgroundBlockColor' => 'rgba(236, 239, 241, 1)',
|
||||
'borderBlockColor' => 'rgba(190, 202, 209, 1)'
|
||||
],
|
||||
'blacklist' => []
|
||||
];
|
||||
|
||||
|
||||
@ -647,7 +650,13 @@ class init extends common {
|
||||
'blog' => [
|
||||
'config' => [
|
||||
'feeds' => true,
|
||||
'feedsLabel' => "Syndication RSS"
|
||||
'feedsLabel' => "Syndication RSS",
|
||||
"editConsent" => "all",
|
||||
"commentMaxlength" => "500",
|
||||
"commentApproved" => false,
|
||||
"commentClose" => false,
|
||||
"commentNotification" => false,
|
||||
"commentGroupNotification" => 1
|
||||
],
|
||||
'posts' => [
|
||||
'mon-premier-article' => [
|
||||
@ -657,7 +666,8 @@ class init extends common {
|
||||
'author' => 'Rémi',
|
||||
'content' => 'Article bien rédigé et très pertinent, bravo !',
|
||||
'createdOn' => 1421748000,
|
||||
'userId' => ''
|
||||
'userId' => '',
|
||||
'approval' => true
|
||||
]
|
||||
],
|
||||
'content' => '<p>Et eodem impetu Domitianum praecipitem per scalas itidem funibus constrinxerunt, eosque coniunctos per ampla spatia civitatis acri raptavere discursu. iamque artuum et membrorum divulsa conpage superscandentes corpora mortuorum ad ultimam truncata deformitatem velut exsaturati mox abiecerunt in flumen.</p><p>Ex his quidam aeternitati se commendari posse per statuas aestimantes eas ardenter adfectant quasi plus praemii de figmentis aereis sensu carentibus adepturi, quam ex conscientia honeste recteque factorum, easque auro curant inbracteari, quod Acilio Glabrioni delatum est primo, cum consiliis armisque regem superasset Antiochum. quam autem sit pulchrum exigua haec spernentem et minima ad ascensus verae gloriae tendere longos et arduos, ut memorat vates Ascraeus, Censorius Cato monstravit. qui interrogatus quam ob rem inter multos... statuam non haberet malo inquit ambigere bonos quam ob rem id non meruerim, quam quod est gravius cur inpetraverim mussitare.</p><p>Latius iam disseminata licentia onerosus bonis omnibus Caesar nullum post haec adhibens modum orientis latera cuncta vexabat nec honoratis parcens nec urbium primatibus nec plebeiis.</p>',
|
||||
|
@ -28,12 +28,12 @@ class maintenance extends common {
|
||||
exit();
|
||||
}
|
||||
// Page perso définie et existante
|
||||
if ($this->getData(['config','page302']) !== 'none'
|
||||
AND $this->getData(['page',$this->getData(['config','page302'])]) ) {
|
||||
if ($this->getData(['locale','page302']) !== 'none'
|
||||
AND $this->getData(['page',$this->getData(['locale','page302'])]) ) {
|
||||
$this->addOutput([
|
||||
'display' => self::DISPLAY_LAYOUT_LIGHT,
|
||||
'title' => $this->getData(['page',$this->getData(['config','page302']),'title']),
|
||||
'content' => $this->getdata(['page',$this->getData(['config','page302']),'content']),
|
||||
'title' => $this->getData(['page',$this->getData(['locale','page302']),'title']),
|
||||
'content' => $this->getdata(['page',$this->getData(['locale','page302']),'content']),
|
||||
'view' => 'index'
|
||||
]);
|
||||
} else {
|
||||
|
@ -194,7 +194,7 @@ class page extends common {
|
||||
]);
|
||||
}
|
||||
// Impossible de supprimer la page d'accueil
|
||||
elseif($url[0] === $this->getData(['config', 'homePageId'])) {
|
||||
elseif($url[0] === $this->getData(['locale', 'homePageId'])) {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
@ -202,7 +202,7 @@ class page extends common {
|
||||
]);
|
||||
}
|
||||
// Impossible de supprimer la page de recherche affectée
|
||||
elseif($url[0] === $this->getData(['config', 'searchPageId'])) {
|
||||
elseif($url[0] === $this->getData(['locale', 'searchPageId'])) {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
@ -210,7 +210,7 @@ class page extends common {
|
||||
]);
|
||||
}
|
||||
// Impossible de supprimer la page des mentions légales affectée
|
||||
elseif($url[0] === $this->getData(['config', 'legalPageId'])) {
|
||||
elseif($url[0] === $this->getData(['locale', 'legalPageId'])) {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
@ -218,7 +218,7 @@ class page extends common {
|
||||
]);
|
||||
}
|
||||
// Impossible de supprimer la page des mentions légales affectée
|
||||
elseif($url[0] === $this->getData(['config', 'page404'])) {
|
||||
elseif($url[0] === $this->getData(['locale', 'page404'])) {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
@ -226,7 +226,7 @@ class page extends common {
|
||||
]);
|
||||
}
|
||||
// Impossible de supprimer la page des mentions légales affectée
|
||||
elseif($url[0] === $this->getData(['config', 'page403'])) {
|
||||
elseif($url[0] === $this->getData(['locale', 'page403'])) {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
@ -234,7 +234,7 @@ class page extends common {
|
||||
]);
|
||||
}
|
||||
// Impossible de supprimer la page des mentions légales affectée
|
||||
elseif($url[0] === $this->getData(['config', 'page302'])) {
|
||||
elseif($url[0] === $this->getData(['locale', 'page302'])) {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . 'config',
|
||||
@ -317,11 +317,13 @@ class page extends common {
|
||||
$this->setData(['page', $childrenPageId, 'parentPageId', $pageId]);
|
||||
}
|
||||
// Change l'id de page dans les données des modules
|
||||
$this->setData(['module', $pageId, $this->getData(['module', $this->getUrl(2)])]);
|
||||
$this->deleteData(['module', $this->getUrl(2)]);
|
||||
if ($this->getData(['module', $this->getUrl(2)]) !== null ) {
|
||||
$this->setData(['module', $pageId, $this->getData(['module', $this->getUrl(2)])]);
|
||||
$this->deleteData(['module', $this->getUrl(2)]);
|
||||
}
|
||||
// Si la page correspond à la page d'accueil, change l'id dans la configuration du site
|
||||
if($this->getData(['config', 'homePageId']) === $this->getUrl(2)) {
|
||||
$this->setData(['config', 'homePageId', $pageId]);
|
||||
if($this->getData(['locale', 'homePageId']) === $this->getUrl(2)) {
|
||||
$this->setData(['locale', 'homePageId', $pageId]);
|
||||
}
|
||||
}
|
||||
// Supprime les données du module en cas de changement de module
|
||||
@ -333,20 +335,20 @@ class page extends common {
|
||||
$this->deleteData(['page', $this->getUrl(2)]);
|
||||
}
|
||||
// Traitement des pages spéciales affectées dans la config :
|
||||
if ($this->getUrl(2) === $this->getData(['config', 'legalPageId']) ) {
|
||||
$this->setData(['config','legalPageId', $pageId]);
|
||||
if ($this->getUrl(2) === $this->getData(['locale', 'legalPageId']) ) {
|
||||
$this->setData(['locale','legalPageId', $pageId]);
|
||||
}
|
||||
if ($this->getUrl(2) === $this->getData(['config', 'searchPageId']) ) {
|
||||
$this->setData(['config','searchPageId', $pageId]);
|
||||
if ($this->getUrl(2) === $this->getData(['locale', 'searchPageId']) ) {
|
||||
$this->setData(['locale','searchPageId', $pageId]);
|
||||
}
|
||||
if ($this->getUrl(2) === $this->getData(['config', 'page404']) ) {
|
||||
$this->setData(['config','page404', $pageId]);
|
||||
if ($this->getUrl(2) === $this->getData(['locale', 'page404']) ) {
|
||||
$this->setData(['locale','page404', $pageId]);
|
||||
}
|
||||
if ($this->getUrl(2) === $this->getData(['config', 'page403']) ) {
|
||||
$this->setData(['config','page403', $pageId]);
|
||||
if ($this->getUrl(2) === $this->getData(['locale', 'page403']) ) {
|
||||
$this->setData(['locale','page403', $pageId]);
|
||||
}
|
||||
if ($this->getUrl(2) === $this->getData(['config', 'page302']) ) {
|
||||
$this->setData(['config','page302', $pageId]);
|
||||
if ($this->getUrl(2) === $this->getData(['locale', 'page302']) ) {
|
||||
$this->setData(['locale','page302', $pageId]);
|
||||
}
|
||||
// Si la page est une page enfant, actualise les positions des autres enfants du parent, sinon actualise les pages sans parents
|
||||
$lastPosition = 1;
|
||||
|
@ -24,7 +24,6 @@ class theme extends common {
|
||||
'index' => self::GROUP_ADMIN,
|
||||
'menu' => self::GROUP_ADMIN,
|
||||
'reset' => self::GROUP_ADMIN,
|
||||
'resetAdmin' => self::GROUP_ADMIN,
|
||||
'site' => self::GROUP_ADMIN,
|
||||
'admin' => self::GROUP_ADMIN,
|
||||
'manage' => self::GROUP_ADMIN,
|
||||
@ -534,30 +533,45 @@ class theme extends common {
|
||||
* Réinitialisation de la personnalisation avancée
|
||||
*/
|
||||
public function reset() {
|
||||
// Supprime le fichier de personnalisation avancée
|
||||
unlink(self::DATA_DIR.'custom.css');
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'notification' => 'Personnalisation avancée réinitialisée',
|
||||
'redirect' => helper::baseUrl() . 'theme/advanced',
|
||||
'state' => true
|
||||
]);
|
||||
// $url prend l'adresse sans le token
|
||||
$url = explode('&',$this->getUrl(2));
|
||||
|
||||
if ( isset($_GET['csrf'])
|
||||
AND $_GET['csrf'] === $_SESSION['csrf']
|
||||
) {
|
||||
// Réinitialisation
|
||||
$redirect ='';
|
||||
switch ($url[0]) {
|
||||
case 'admin':
|
||||
$this->initData('admin');
|
||||
$redirect = helper::baseUrl() . 'theme/admin';
|
||||
break;
|
||||
case 'manage':
|
||||
$this->initData('theme');
|
||||
$redirect = helper::baseUrl() . 'theme/manage';
|
||||
break;
|
||||
case 'custom':
|
||||
unlink(self::DATA_DIR.'custom.css');
|
||||
$redirect = helper::baseUrl() . 'theme/advanced';
|
||||
break;
|
||||
default :
|
||||
$redirect = helper::baseUrl() . 'theme';
|
||||
}
|
||||
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'notification' => 'Réinitialisation effectuée',
|
||||
'redirect' => $redirect,
|
||||
'state' => true
|
||||
]);
|
||||
} else {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'notification' => 'Jeton incorrect'
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Réinitialisation de la personnalisation avancée
|
||||
*/
|
||||
public function resetAdmin() {
|
||||
// Supprime le fichier de personnalisation avancée
|
||||
//unlink(self::DATA_DIR.'admin.json');
|
||||
$this->initData('admin');
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'notification' => 'Thème réinitialisé',
|
||||
'redirect' => helper::baseUrl() . 'theme/admin',
|
||||
'state' => true
|
||||
]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Options du site
|
||||
|
@ -32,7 +32,7 @@ $("input, select").on("change", function() {
|
||||
var colors = core.colorVariants($("#adminColorRed").val());
|
||||
css += ".button.buttonRed {background-color: " + colors.normal + ";color:" + colors.text + ";}.button.buttonRed:hover {background-color:" + colors.darken + ";color:" + colors.text + "}.button.buttonRed:active {background-color:" + colors.veryDarken + ";color:" + colors.text + "}";
|
||||
var colors = core.colorVariants($("#adminColorGreen").val());
|
||||
css += "button[type=submit] {background-color: " + colors.normal + ";color: " + ";color:" + colors.text + "}button[type=submit]:hover {background-color: " + colors.darken + ";color:" + colors.text + ";}button[type=submit]:active {background-color:" + colors.veryDarken + ";color:" + colors.text + "}";
|
||||
css += ".button.buttonGreen, button[type=submit] {background-color: " + colors.normal + ";color: " + ";color:" + colors.text + "}.button.buttonGreen:hover, button[type=submit]:hover {background-color: " + colors.darken + ";color:" + colors.text + ";}.button.buttonGreen:active, button[type=submit]:active {background-color:" + colors.veryDarken + ";color:" + colors.text + "}";
|
||||
var colors = core.colorVariants($("#adminBackGroundBlockColor").val());
|
||||
css += ".block {border: 1px solid " + $("#adminBorderBlockColor").val() + ";}.block h4 {background-color: " + colors.normal + ";color:" + colors.text + ";}";
|
||||
css += "input[type=email],input[type=text],input[type=password],select:not(#barSelectPage),textarea:not(.editorWysiwyg),.inputFile{background-color: " + colors.normal + ";color:" + colors.text + ";border: 1px solid " + $("#adminBorderBlockColor").val() + ";}";
|
||||
@ -46,3 +46,13 @@ $("input, select").on("change", function() {
|
||||
.appendTo("head");
|
||||
|
||||
});
|
||||
|
||||
/**
|
||||
* Confirmation de réinitialisation
|
||||
*/
|
||||
$("#configAdminReset").on("click", function() {
|
||||
var _this = $(this);
|
||||
return core.confirm("Êtes-vous sûr de vouloir réinitialiser à son état d'origine le thème de l\'administration ?", function() {
|
||||
$(location).attr("href", _this.attr("href"));
|
||||
});
|
||||
});
|
||||
|
@ -16,7 +16,7 @@
|
||||
<div class="col2 offset">
|
||||
<?php echo template::button('configAdminReset', [
|
||||
'class' => 'buttonRed',
|
||||
'href' => helper::baseUrl() . 'theme/resetAdmin',
|
||||
'href' => helper::baseUrl() . 'theme/reset/admin' . '&csrf=' . $_SESSION['csrf'],
|
||||
'value' => 'Réinitialiser',
|
||||
'ico' => 'cancel'
|
||||
]); ?>
|
||||
|
@ -10,7 +10,7 @@
|
||||
</div>
|
||||
<div class="col2 offset6">
|
||||
<?php echo template::button('themeAdvancedReset', [
|
||||
'href' => helper::baseUrl() . 'theme/reset',
|
||||
'href' => helper::baseUrl() . 'theme/reset/custom' . '&csrf=' . $_SESSION['csrf'],
|
||||
'class' => 'buttonRed',
|
||||
'ico' => 'cancel',
|
||||
'value' => 'Réinitialiser'
|
||||
|
@ -21,15 +21,25 @@ $(document).ready(function(){
|
||||
* Aperçu en direct
|
||||
*/
|
||||
$("input, select").on("change", function() {
|
||||
|
||||
// Option fixe pour contain et cover
|
||||
var themeBodyImageSize = $("#themeBodyImageSize").val();
|
||||
|
||||
if(themeBodyImageSize === "cover" ||
|
||||
themeBodyImageSize === "contain" ) {
|
||||
$("#themeBodyImageAttachment").val("fixed");
|
||||
}
|
||||
|
||||
// Couleur du fond
|
||||
var css = "body{background-color:" + $("#themeBodyBackgroundColor").val() + "}";
|
||||
var css = "html{background-color:" + $("#themeBodyBackgroundColor").val() + "}";
|
||||
// Image du fond
|
||||
var themeBodyImage = $("#themeBodyImage").val();
|
||||
if(themeBodyImage) {
|
||||
css += "body{background-image:url('<?php echo helper::baseUrl(false); ?>site/file/source/" + themeBodyImage + "');background-repeat:" + $("#themeBodyImageRepeat").val() + ";background-position:" + $("#themeBodyImagePosition").val() + ";background-attachment:" + $("#themeBodyImageAttachment").val() + ";background-size:" + $("#themeBodyImageSize").val() + "}";
|
||||
css += "html{background-image:url('<?php echo helper::baseUrl(false); ?>site/file/source/" + themeBodyImage + "');background-repeat:" + $("#themeBodyImageRepeat").val() + ";background-position:" + $("#themeBodyImagePosition").val() + ";background-attachment:" + $("#themeBodyImageAttachment").val() + ";background-size:" + $("#themeBodyImageSize").val() + "}";
|
||||
css += "html{background-color:rgba(0,0,0,0);}";
|
||||
}
|
||||
else {
|
||||
css += "body{background-image:none}";
|
||||
css += "html{background-image:none}";
|
||||
}
|
||||
css += '#backToTop {background-color:' + $("#themeBodyToTopBackground").val() + ';color:' + $("#themeBodyToTopColor").val() + ';}';
|
||||
|
||||
|
@ -79,16 +79,16 @@
|
||||
<div class="row">
|
||||
<div class="col6">
|
||||
<?php echo template::checkbox('themeFooterDisplayLegal', true, 'Mentions légales', [
|
||||
'checked' => $this->getData(['config', 'legalPageId']) === 'none' ? false : $this->getData(['theme', 'footer', 'displayLegal']),
|
||||
'disabled' => $this->getData(['config', 'legalPageId']) === 'none' ? true : false,
|
||||
'help' => $this->getData(['config', 'legalPageId']) === 'none' ? 'Pour activer cette option, sélectionnez la page contenant les mentions légales dans la configuration du site' : ''
|
||||
'checked' => $this->getData(['locale', 'legalPageId']) === 'none' ? false : $this->getData(['theme', 'footer', 'displayLegal']),
|
||||
'disabled' => $this->getData(['locale', 'legalPageId']) === 'none' ? true : false,
|
||||
'help' => $this->getData(['locale', 'legalPageId']) === 'none' ? 'Pour activer cette option, sélectionnez la page contenant les mentions légales dans la configuration du site' : ''
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col6">
|
||||
<?php echo template::checkbox('themeFooterDisplaySearch', true, 'Rechercher dans le site', [
|
||||
'checked' => $this->getData(['config', 'searchPageId']) === 'none' ? false : $this->getData(['theme', 'footer', 'displaySearch']),
|
||||
'disabled' => $this->getData(['config', 'searchPageId']) === 'none' ? true : false,
|
||||
'help' => $this->getData(['config', 'searchPageId']) === 'none' ? 'Pour activer cette option, sélectionnez la page contenant un module de recherche dans la configuration du site' : ''
|
||||
'checked' => $this->getData(['locale', 'searchPageId']) === 'none' ? false : $this->getData(['theme', 'footer', 'displaySearch']),
|
||||
'disabled' => $this->getData(['locale', 'searchPageId']) === 'none' ? true : false,
|
||||
'help' => $this->getData(['locale', 'searchPageId']) === 'none' ? 'Pour activer cette option, sélectionnez la page contenant un module de recherche dans la configuration du site' : ''
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
21
core/module/theme/view/manage/manage.js.php
Executable file
@ -0,0 +1,21 @@
|
||||
/**
|
||||
* This file is part of Zwii.
|
||||
*
|
||||
* For full copyright and license information, please see the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*
|
||||
* @author Rémi Jean <remi.jean@outlook.com>
|
||||
* @copyright Copyright (C) 2008-2018, Rémi Jean
|
||||
* @license GNU General Public License, version 3
|
||||
* @link http://zwiicms.fr/
|
||||
*/
|
||||
|
||||
/**
|
||||
* Confirmation de réinitialisation
|
||||
*/
|
||||
$("#configManageReset").on("click", function() {
|
||||
var _this = $(this);
|
||||
return core.confirm("Êtes-vous sûr de vouloir réinitialiser à son état d'origine le thème du site ?", function() {
|
||||
$(location).attr("href", _this.attr("href"));
|
||||
});
|
||||
});
|
@ -8,53 +8,59 @@
|
||||
'value' => 'Retour'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2 offset6">
|
||||
<?php echo template::button('configManageReset', [
|
||||
'class' => 'buttonRed',
|
||||
'href' => helper::baseUrl() . 'theme/reset/manage' . '&csrf=' . $_SESSION['csrf'],
|
||||
'value' => 'Réinitialiser',
|
||||
'ico' => 'cancel'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::submit('themeImportSubmit', [
|
||||
'value' => 'Appliquer'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col6">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Installer un thème archivé</h4>
|
||||
<h4>Installer un thème archivé (site ou administration)</h4>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="col6 offset3">
|
||||
<?php echo template::file('themeManageImport', [
|
||||
'label' => 'Archive ZIP :',
|
||||
'type' => 2
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col5 offset3">
|
||||
<?php echo template::submit('themeImportSubmit', [
|
||||
'value' => 'Appliquer'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col6">
|
||||
<div class="block">
|
||||
<h4>Sauvegarder le thème</h4>
|
||||
<h4>Sauvegarde du thème dans les <a href="<?php echo helper::baseUrl(false); ?>core/vendor/filemanager/dialog.php?fldr=theme&type=0&akey=<?php echo md5_file(self::DATA_DIR.'core.json'); ?>" data-lity>fichiers</a> du site</h4>
|
||||
<div class="row">
|
||||
<div class="col6">
|
||||
<?php echo template::button('themeSave', [
|
||||
'href' => helper::baseUrl() . 'theme/save/theme',
|
||||
'ico' => 'download-cloud',
|
||||
'value' => 'Thème site'
|
||||
'value' => 'Thème du site'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col6">
|
||||
<?php echo template::button('themeSaveAdmin', [
|
||||
'href' => helper::baseUrl() . 'theme/save/admin',
|
||||
'ico' => 'download-cloud',
|
||||
'value' => 'Thème administration'
|
||||
'value' => 'Thème de l\'administration'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<em>Le fichier de sauvegarde est généré dans <a href="<?php echo helper::baseUrl(false); ?>core/vendor/filemanager/dialog.php?fldr=theme&type=0&akey=<?php echo md5_file(self::DATA_DIR.'core.json'); ?>" data-lity>le dossier Thème</a> du gestionnaire de fichiers.</em>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col6">
|
||||
<div class="block">
|
||||
<h4>Télécharger le thème</h4>
|
||||
<div class="row">
|
||||
@ -62,14 +68,14 @@
|
||||
<?php echo template::button('themeExport', [
|
||||
'href' => helper::baseUrl() . 'theme/export/theme',
|
||||
'ico' => 'download',
|
||||
'value' => 'Thème site'
|
||||
'value' => 'Thème du site'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col6">
|
||||
<?php echo template::button('themeExport', [
|
||||
'href' => helper::baseUrl() . 'theme/export/admin',
|
||||
'ico' => 'download',
|
||||
'value' => 'Thème administration'
|
||||
'value' => 'Thème de l\'administration'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -178,8 +178,7 @@
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('themeMenuLoginLink', true, 'Lien de connexion', [
|
||||
'checked' => $this->getData(['theme', 'menu', 'loginLink']),
|
||||
'help' => 'L\'activation de cette option n\'est pas recommandée'
|
||||
'checked' => $this->getData(['theme', 'menu', 'loginLink'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
|
BIN
core/module/translate/ressource/de.png
Executable file
After Width: | Height: | Size: 119 B |
BIN
core/module/translate/ressource/en.png
Executable file
After Width: | Height: | Size: 1.2 KiB |
BIN
core/module/translate/ressource/es.png
Executable file
After Width: | Height: | Size: 287 B |
BIN
core/module/translate/ressource/fr.png
Executable file
After Width: | Height: | Size: 96 B |
BIN
core/module/translate/ressource/googtrans.png
Executable file
After Width: | Height: | Size: 3.4 KiB |
BIN
core/module/translate/ressource/it.png
Executable file
After Width: | Height: | Size: 96 B |
BIN
core/module/translate/ressource/nl.png
Executable file
After Width: | Height: | Size: 108 B |
BIN
core/module/translate/ressource/pt.png
Executable file
After Width: | Height: | Size: 395 B |
109
core/module/translate/translate.php
Executable file
@ -0,0 +1,109 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* This file is part of Zwii.
|
||||
*
|
||||
* For full copyright and license information, please see the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*
|
||||
* @author Rémi Jean <remi.jean@outlook.com>
|
||||
* @copyright Copyright (C) 2008-2018, Rémi Jean
|
||||
* @license GNU General Public License, version 3
|
||||
* @link http://zwiicms.fr/
|
||||
*/
|
||||
|
||||
class translate extends common {
|
||||
|
||||
public static $actions = [
|
||||
/*'config' => self::GROUP_MODERATOR,*/
|
||||
'index' => self::GROUP_MODERATOR,
|
||||
'language' => self::GROUP_VISITOR
|
||||
];
|
||||
|
||||
/**
|
||||
* Configuration
|
||||
*/
|
||||
public function index() {
|
||||
|
||||
// Soumission du formulaire
|
||||
if($this->isPost()) {
|
||||
// Edtion des langues
|
||||
foreach (self::$i18nList as $keyi18n => $value) {
|
||||
if ($keyi18n === 'fr') {continue;}
|
||||
// Effacement d'une langue installée (dossier plus option désactivée précédemment)
|
||||
if ( is_dir( self::DATA_DIR . $keyi18n ) === true
|
||||
AND $this->getInput('translateSiteFlag' . strtoupper($keyi18n) , helper::FILTER_BOOLEAN) === false )
|
||||
{
|
||||
$this->removeDir( self::DATA_DIR . $keyi18n);
|
||||
}
|
||||
// Installation d'une langue
|
||||
if ( $this->getInput('translateSiteFlag' . strtoupper($keyi18n) , helper::FILTER_BOOLEAN) === true )
|
||||
{
|
||||
// Créer le dossier
|
||||
if (is_dir( self::DATA_DIR . $keyi18n ) === false ) {
|
||||
mkdir( self::DATA_DIR . $keyi18n);
|
||||
}
|
||||
// Charger les modèles
|
||||
require_once('core/module/install/ressource/defaultdata.php');
|
||||
// Nouvelle instance des pages, module, locale
|
||||
$files = ['page','module','locale'];
|
||||
foreach ($files as $keyFile) {
|
||||
echo $keyFile;
|
||||
$e = new \Prowebcraft\JsonDb([
|
||||
'name' => $keyFile . '.json',
|
||||
'dir' => $this->dataPath ($keyFile,$keyi18n)
|
||||
]);;
|
||||
$e->set($keyFile, init::$defaultData[$keyFile]);
|
||||
$e->save();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Enregistrement des données
|
||||
$this->setData(['config','translate', [
|
||||
'scriptGoogle' => $this->getInput('translateScriptGoogle', helper::FILTER_BOOLEAN),
|
||||
'showCredits' => $this->getInput('translateCredits', helper::FILTER_BOOLEAN) ? $this->getInput('translateCredits', helper::FILTER_BOOLEAN) : false,
|
||||
'autoDetect' => $this->getInput('translateAutoDetect', helper::FILTER_BOOLEAN),
|
||||
'admin' => $this->getInput('translateAdmin', helper::FILTER_BOOLEAN),
|
||||
'scriptFR' => $this->getInput('translateScriptFlagFR', helper::FILTER_BOOLEAN),
|
||||
'scriptDE' => $this->getInput('translateScriptFlagDE', helper::FILTER_BOOLEAN),
|
||||
'scriptEN' => $this->getInput('translateScriptFlagEN', helper::FILTER_BOOLEAN),
|
||||
'scriptES' => $this->getInput('translateScriptFlagES', helper::FILTER_BOOLEAN),
|
||||
'scriptIT' => $this->getInput('translateScriptFlagIT', helper::FILTER_BOOLEAN),
|
||||
'scriptNL' => $this->getInput('translateScriptFlagNL', helper::FILTER_BOOLEAN),
|
||||
'scriptPT' => $this->getInput('translateScriptFlagPT', helper::FILTER_BOOLEAN),
|
||||
'site' => $this->getInput('translateSite', helper::FILTER_BOOLEAN),
|
||||
'siteFR' => $this->getInput('translateSiteFlagFR', helper::FILTER_BOOLEAN),
|
||||
'siteDE' => $this->getInput('translateSiteFlagDE', helper::FILTER_BOOLEAN),
|
||||
'siteEN' => $this->getInput('translateSiteFlagEN', helper::FILTER_BOOLEAN),
|
||||
'siteES' => $this->getInput('translateSiteFlagES', helper::FILTER_BOOLEAN),
|
||||
'siteIT' => $this->getInput('translateSiteFlagIT', helper::FILTER_BOOLEAN),
|
||||
'siteNL' => $this->getInput('translateSiteFlagNL', helper::FILTER_BOOLEAN),
|
||||
'sitePT' => $this->getInput('translateSiteFlagPT', helper::FILTER_BOOLEAN)
|
||||
]]);
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl(),
|
||||
'notification' => 'Modifications enregistrées',
|
||||
'state' => true
|
||||
]);
|
||||
}
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'title' => 'Paramètres',
|
||||
'view' => 'index'
|
||||
]);
|
||||
}
|
||||
|
||||
/*
|
||||
* Traitement du changement de langues
|
||||
*/
|
||||
public function language() {
|
||||
// Transmettre le choix au noyau
|
||||
setcookie('ZWII_USER_I18N', $this->getUrl(2), time() + 3600, helper::baseUrl(false, false) , '', helper::isHttps(), true);
|
||||
// Valeurs en sortie sans post
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl(3)
|
||||
]);
|
||||
}
|
||||
}
|
20
core/module/translate/view/index/index.css
Executable file
@ -0,0 +1,20 @@
|
||||
/**
|
||||
* This file is part of Zwii.
|
||||
*
|
||||
* For full copyright and license information, please see the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*
|
||||
* @author Rémi Jean <remi.jean@outlook.com>
|
||||
* @copyright Copyright (C) 2008-2018, Rémi Jean
|
||||
* @author Frédéric Tempez <frederic.tempez@outlook.com>
|
||||
* @copyright Copyright (C) 2018-2020, Frédéric Tempez
|
||||
* @license GNU General Public License, version 3
|
||||
* @link http://zwiicms.fr/
|
||||
*/
|
||||
|
||||
|
||||
/** @import url("site/data/admin.css"); */
|
||||
|
||||
/** NE PAS EFFACER
|
||||
* admin.css
|
||||
*/
|
124
core/module/translate/view/index/index.php
Executable file
@ -0,0 +1,124 @@
|
||||
<?php echo template::formOpen('translateForm'); ?>
|
||||
<div class="row">
|
||||
<div class="col2">
|
||||
<?php echo template::button('translateFormBack', [
|
||||
'class' => 'buttonGrey',
|
||||
'href' => helper::baseUrl(),
|
||||
'ico' => 'left',
|
||||
'value' => 'Retour'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2 offset8">
|
||||
<?php echo template::submit('translateFormSubmit'); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Langues supportées</h4>
|
||||
<div class="row">
|
||||
<div class="col6">
|
||||
<b>Traduction automatique :</b>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateScriptFlagDE', true, 'Allemand', [
|
||||
'checked' => $this->getData(['config','translate', 'scriptDE'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateScriptFlagEN', true, 'Anglais', [
|
||||
'checked' => $this->getData(['config','translate', 'scriptEN'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateScriptFlagES', true, 'Espagnol', [
|
||||
'checked' => $this->getData(['config','translate', 'scriptES'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateScriptFlagIT', true, 'Italien', [
|
||||
'checked' => $this->getData(['config','translate', 'scriptIT'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateScriptFlagNL', true, 'Néerlandais', [
|
||||
'checked' => $this->getData(['config','translate', 'scriptNL'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateScriptFlagPT', true, 'Portugais', [
|
||||
'checked' => $this->getData(['config','translate', 'scriptPT'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateAutoDetect', true, 'Détection automatique', [
|
||||
'checked' => $this->getData(['config','translate', 'autoDetect']),
|
||||
'help' => 'Détecte la langue du navigateur.'
|
||||
]); ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="col6">
|
||||
<b>Traduction rédigée :</b>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateSiteFlagEN', true, 'Anglais', [
|
||||
'checked' => $this->getData(['config', 'translate', 'siteEN'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateSiteFlagDE', true, 'Allemand', [
|
||||
'checked' => $this->getData(['config', 'translate', 'siteDE'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateSiteFlagES', true, 'Espagnol', [
|
||||
'checked' => $this->getData(['config', 'translate', 'siteES'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateSiteFlagIT', true, 'Italien', [
|
||||
'checked' => $this->getData(['config', 'translate', 'siteIT'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateSiteFlagNL', true, 'Néerlandais', [
|
||||
'checked' => $this->getData(['config', 'translate', 'siteNL'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('translateSiteFlagPT', true, 'Portugais', [
|
||||
'checked' => $this->getData(['config', 'translate', 'sitePT'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Paramètres de traduction automatique</h4>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('translateScriptGoogle', true, 'Active le script de traduction automatique', [
|
||||
'checked' => $this->getData(['config','translate', 'scriptGoogle'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('translateAdmin', true, 'Mode connexion', [
|
||||
'checked' => $this->getData(['config','translate', 'admin']),
|
||||
'help' => 'Traduction automatique du site et de l\'interface du CMS'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::checkbox('translateCredits', true, 'Afficher les crédits du script Google', [
|
||||
'checked' => $this->getData(['config','translate', 'showCredits']),
|
||||
'help' => 'Option vivement recommandée pour le respect du droit d\'auteur'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php echo template::formClose(); ?>
|
8
core/module/user/ressource/.htaccess
Executable file
@ -0,0 +1,8 @@
|
||||
# Bloque l'accès aux données
|
||||
Order deny,allow
|
||||
Deny from all
|
||||
# Sauf l'accès au modèle csv
|
||||
<Files template.csv>
|
||||
Order Allow,Deny
|
||||
Allow from all
|
||||
</Files>
|
2
core/module/user/ressource/template.csv
Executable file
@ -0,0 +1,2 @@
|
||||
id;nom;prenom;email;groupe
|
||||
jbon;Bon;Jean;jean.bon@email.fr;1
|
|
@ -17,20 +17,35 @@ class user extends common {
|
||||
public static $actions = [
|
||||
'add' => self::GROUP_ADMIN,
|
||||
'delete' => self::GROUP_ADMIN,
|
||||
'edit' => self::GROUP_MEMBER,
|
||||
'forgot' => self::GROUP_VISITOR,
|
||||
'import' => self::GROUP_ADMIN,
|
||||
'index' => self::GROUP_ADMIN,
|
||||
'login' => self::GROUP_VISITOR,
|
||||
'edit' => self::GROUP_MEMBER,
|
||||
'logout' => self::GROUP_MEMBER,
|
||||
'forgot' => self::GROUP_VISITOR,
|
||||
'login' => self::GROUP_VISITOR,
|
||||
'reset' => self::GROUP_VISITOR
|
||||
];
|
||||
|
||||
public static $users = [];
|
||||
|
||||
//Paramètres pour choix de la signature
|
||||
public static $signature = [
|
||||
self::SIGNATURE_ID => 'Identifiant',
|
||||
self::SIGNATURE_PSEUDO => 'Pseudo',
|
||||
self::SIGNATURE_FIRSTLASTNAME => 'Prénom Nom',
|
||||
self::SIGNATURE_LASTFIRSTNAME => 'Nom Prénom'
|
||||
];
|
||||
|
||||
public static $userId = '';
|
||||
|
||||
public static $userLongtime = false;
|
||||
|
||||
public static $separators = [
|
||||
';' => ';',
|
||||
',' => ',',
|
||||
':' => ':'
|
||||
];
|
||||
|
||||
/**
|
||||
* Ajout
|
||||
*/
|
||||
@ -63,8 +78,15 @@ class user extends common {
|
||||
'forgot' => 0,
|
||||
'group' => $this->getInput('userAddGroup', helper::FILTER_INT, true),
|
||||
'lastname' => $userLastname,
|
||||
'pseudo' => $this->getInput('userAddPseudo', helper::FILTER_STRING_SHORT, true),
|
||||
'signature' => $this->getInput('userAddSignature', helper::FILTER_INT, true),
|
||||
'mail' => $userMail,
|
||||
'password' => $this->getInput('userAddPassword', helper::FILTER_PASSWORD, true),
|
||||
"connectFail" => null,
|
||||
"connectTimeout" => null,
|
||||
"accessUrl" => null,
|
||||
"accessTimer" => null,
|
||||
"accessCsrf" => null
|
||||
]
|
||||
]);
|
||||
|
||||
@ -73,11 +95,10 @@ class user extends common {
|
||||
if($this->getInput('userAddSendMail', helper::FILTER_BOOLEAN) && $check === true) {
|
||||
$sent = $this->sendMail(
|
||||
$userMail,
|
||||
'Compte créé sur ' . $this->getData(['config', 'title']),
|
||||
'Compte créé sur ' . $this->getData(['locale', 'title']),
|
||||
'Bonjour <strong>' . $userFirstname . ' ' . $userLastname . '</strong>,<br><br>' .
|
||||
'Un administrateur vous a créé un compte sur le site ' . $this->getData(['config', 'title']) . '. Vous trouverez ci-dessous les détails de votre compte.<br><br>' .
|
||||
'Un administrateur vous a créé un compte sur le site ' . $this->getData(['locale', 'title']) . '. Vous trouverez ci-dessous les détails de votre compte.<br><br>' .
|
||||
'<strong>Identifiant du compte :</strong> ' . $this->getInput('userAddId') . '<br>' .
|
||||
'<strong>Mot de passe du compte :</strong> ' . $this->getInput('userAddPassword') . '<br><br>' .
|
||||
'<small>Nous ne conservons pas les mots de passe, en conséquence nous vous conseillons de conserver ce message tant que vous ne vous êtes pas connecté. Vous pourrez modifier votre mot de passe après votre première connexion.</small>',
|
||||
null
|
||||
);
|
||||
@ -208,15 +229,26 @@ class user extends common {
|
||||
else {
|
||||
$newGroup = $this->getData(['user', $this->getUrl(2), 'group']);
|
||||
}
|
||||
// Modification de nom Prénom
|
||||
if($this->getUser('group') === self::GROUP_ADMIN){
|
||||
$newfirstname = $this->getInput('userEditFirstname', helper::FILTER_STRING_SHORT, true);
|
||||
$newlastname = $this->getInput('userEditLastname', helper::FILTER_STRING_SHORT, true);
|
||||
}
|
||||
else{
|
||||
$newfirstname = $this->getData(['user', $this->getUrl(2), 'firstname']);
|
||||
$newlastname = $this->getData(['user', $this->getUrl(2), 'lastname']);
|
||||
}
|
||||
// Modifie l'utilisateur
|
||||
$this->setData([
|
||||
'user',
|
||||
$this->getUrl(2),
|
||||
[
|
||||
'firstname' => $this->getInput('userEditFirstname', helper::FILTER_STRING_SHORT, true),
|
||||
'firstname' => $newfirstname,
|
||||
'forgot' => 0,
|
||||
'group' => $newGroup,
|
||||
'lastname' => $this->getInput('userEditLastname', helper::FILTER_STRING_SHORT, true),
|
||||
'lastname' => $newlastname,
|
||||
'pseudo' => $this->getInput('userEditPseudo', helper::FILTER_STRING_SHORT, true),
|
||||
'signature' => $this->getInput('userEditSignature', helper::FILTER_INT, true),
|
||||
'mail' => $this->getInput('userEditMail', helper::FILTER_MAIL, true),
|
||||
'password' => $newPassword,
|
||||
'connectFail' => $this->getData(['user',$this->getUrl(2),'connectFail']),
|
||||
@ -231,12 +263,12 @@ class user extends common {
|
||||
$redirect = helper::baseUrl() . 'user/login/' . str_replace('/', '_', $this->getUrl());
|
||||
}
|
||||
// Redirection si retour en arrière possible
|
||||
elseif($this->getUrl(3)) {
|
||||
elseif($this->getUser('group') === 3) {
|
||||
$redirect = helper::baseUrl() . 'user';
|
||||
}
|
||||
// Redirection normale
|
||||
else {
|
||||
$redirect = helper::baseUrl() . $this->getUrl();
|
||||
$redirect = helper::baseUrl();
|
||||
}
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
@ -554,4 +586,131 @@ class user extends common {
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Importation CSV d'utilisateurs
|
||||
*/
|
||||
public function import() {
|
||||
// Soumission du formulaire
|
||||
$notification = '';
|
||||
$success = true;
|
||||
if($this->isPost()) {
|
||||
// Lecture du CSV et construction du tableau
|
||||
$file = $this->getInput('userImportCSVFile',helper::FILTER_STRING_SHORT, true);
|
||||
$filePath = self::FILE_DIR . 'source/' . $file;
|
||||
if ($file AND file_exists($filePath)) {
|
||||
// Analyse et extraction du CSV
|
||||
$rows = array_map(function($row) { return str_getcsv($row, $this->getInput('userImportSeparator') ); }, file($filePath));
|
||||
$header = array_shift($rows);
|
||||
$csv = array();
|
||||
foreach($rows as $row) {
|
||||
$csv[] = array_combine($header, $row);
|
||||
}
|
||||
// Traitement des données
|
||||
foreach($csv as $item ) {
|
||||
// Données valides
|
||||
if( array_key_exists('id', $item)
|
||||
AND array_key_exists('prenom',$item)
|
||||
AND array_key_exists('nom',$item)
|
||||
AND array_key_exists('groupe',$item)
|
||||
AND array_key_exists('email',$item)
|
||||
AND $item['nom']
|
||||
AND $item['prenom']
|
||||
AND $item['id']
|
||||
AND $item['email']
|
||||
AND $item['groupe']
|
||||
) {
|
||||
// Validation du groupe
|
||||
$item['groupe'] = (int) $item['groupe'];
|
||||
$item['groupe'] = ( $item['groupe'] >= self::GROUP_BANNED AND $item['groupe'] <= self::GROUP_ADMIN )
|
||||
? $item['groupe'] : 1;
|
||||
// L'utilisateur existe
|
||||
if ( $this->getData(['user',helper::filter($item['id'] , helper::FILTER_ID)]))
|
||||
{
|
||||
// Notification du doublon
|
||||
$item['notification'] = template::ico('cancel');
|
||||
// Création du tableau de confirmation
|
||||
self::$users[] = [
|
||||
helper::filter($item['id'] , helper::FILTER_ID),
|
||||
$item['nom'],
|
||||
$item['prenom'],
|
||||
self::$groups[$item['groupe']],
|
||||
$item['prenom'],
|
||||
helper::filter($item['email'] , helper::FILTER_MAIL),
|
||||
$item['notification']
|
||||
];
|
||||
// L'utilisateur n'existe pas
|
||||
} else {
|
||||
// Nettoyage de l'identifiant
|
||||
$userId = helper::filter($item['id'] , helper::FILTER_ID);
|
||||
// Enregistre le user
|
||||
$create = $this->setData([
|
||||
'user',
|
||||
$userId, [
|
||||
'firstname' => $item['prenom'],
|
||||
'forgot' => 0,
|
||||
'group' => $item['groupe'] ,
|
||||
'lastname' => $item['nom'],
|
||||
'mail' => $item['email'],
|
||||
'pseudo' => $item['prenom'],
|
||||
'signature' => 1, // Pseudo
|
||||
'password' => uniqid(), // A modifier à la première connexion
|
||||
"connectFail" => null,
|
||||
"connectTimeout" => null,
|
||||
"accessUrl" => null,
|
||||
"accessTimer" => null,
|
||||
"accessCsrf" => null
|
||||
]]);
|
||||
// Icône de notification
|
||||
$item['notification'] = $create ? template::ico('check') : template::ico('cancel');
|
||||
// Envoi du mail
|
||||
if ($create
|
||||
AND $this->getInput('userImportNotification',helper::FILTER_BOOLEAN) === true) {
|
||||
$sent = $this->sendMail(
|
||||
$item['email'],
|
||||
'Compte créé sur ' . $this->getData(['locale', 'title']),
|
||||
'Bonjour <strong>' . $item['prenom'] . ' ' . $item['nom'] . '</strong>,<br><br>' .
|
||||
'Un administrateur vous a créé un compte sur le site ' . $this->getData(['locale', 'title']) . '. Vous trouverez ci-dessous les détails de votre compte.<br><br>' .
|
||||
'<strong>Identifiant du compte :</strong> ' . $userId . '<br>' .
|
||||
'<small>Un mot de passe provisoire vous été attribué, à la première connexion cliquez sur Mot de passe Oublié.</small>'
|
||||
);
|
||||
if ($sent === true) {
|
||||
// Mail envoyé changement de l'icône
|
||||
$item['notification'] = template::ico('mail') ;
|
||||
}
|
||||
}
|
||||
// Création du tableau de confirmation
|
||||
self::$users[] = [
|
||||
$userId,
|
||||
$item['nom'],
|
||||
$item['prenom'],
|
||||
self::$groups[$item['groupe']],
|
||||
$item['prenom'],
|
||||
$item['email'],
|
||||
$item['notification']
|
||||
];
|
||||
}
|
||||
}
|
||||
}
|
||||
if (empty(self::$users)) {
|
||||
$notification = 'Rien à importer, erreur de format ou fichier incorrect' ;
|
||||
$success = false;
|
||||
} else {
|
||||
$notification = 'Importation effectuée' ;
|
||||
$success = true;
|
||||
}
|
||||
} else {
|
||||
$notification = 'Erreur de lecture, vérifiez les permissions';
|
||||
$success = false;
|
||||
}
|
||||
}
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'title' => 'Importation',
|
||||
'view' => 'import',
|
||||
'notification' => $notification,
|
||||
'state' => $success
|
||||
]);
|
||||
}
|
||||
|
||||
}
|
@ -30,6 +30,14 @@
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php echo template::text('userAddPseudo', [
|
||||
'autocomplete' => 'off',
|
||||
'label' => 'Pseudo'
|
||||
]); ?>
|
||||
<?php echo template::select('userAddSignature', $module::$signature, [
|
||||
'label' => 'Signature',
|
||||
'selected' => 1
|
||||
]); ?>
|
||||
<?php echo template::mail('userAddMail', [
|
||||
'autocomplete' => 'off',
|
||||
'label' => 'Adresse mail'
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php echo template::formOpen('userEditForm'); ?>
|
||||
<div class="row">
|
||||
<div class="col2">
|
||||
<?php if($this->getUser('group') === self::GROUP_ADMIN): ?>
|
||||
<?php if($this->getUser('group') === self::GROUP_ADMIN): ?>
|
||||
<?php echo template::button('userEditBack', [
|
||||
'class' => 'buttonGrey',
|
||||
'href' => helper::baseUrl() . 'user',
|
||||
@ -29,6 +29,7 @@
|
||||
<div class="col6">
|
||||
<?php echo template::text('userEditFirstname', [
|
||||
'autocomplete' => 'off',
|
||||
'disabled' => $this->getUser('group') > 2 ? false : true,
|
||||
'label' => 'Prénom',
|
||||
'value' => $this->getData(['user', $this->getUrl(2), 'firstname'])
|
||||
]); ?>
|
||||
@ -36,11 +37,21 @@
|
||||
<div class="col6">
|
||||
<?php echo template::text('userEditLastname', [
|
||||
'autocomplete' => 'off',
|
||||
'disabled' => $this->getUser('group') > 2 ? false : true,
|
||||
'label' => 'Nom',
|
||||
'value' => $this->getData(['user', $this->getUrl(2), 'lastname'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php echo template::text('userEditPseudo', [
|
||||
'autocomplete' => 'off',
|
||||
'label' => 'Pseudo',
|
||||
'value' => $this->getData(['user', $this->getUrl(2), 'pseudo'])
|
||||
]); ?>
|
||||
<?php echo template::select('userEditSignature', $module::$signature, [
|
||||
'label' => 'Signature',
|
||||
'selected' => $this->getData(['user', $this->getUrl(2), 'signature'])
|
||||
]); ?>
|
||||
<?php echo template::mail('userEditMail', [
|
||||
'autocomplete' => 'off',
|
||||
'label' => 'Adresse mail',
|
||||
|
@ -5,7 +5,6 @@
|
||||
<div class="row">
|
||||
<div class="col3 offset6">
|
||||
<?php echo template::button('userForgotBack', [
|
||||
'class' => 'buttonGrey',
|
||||
'href' => helper::baseUrl() . 'user/login/' . $this->getUrl(2),
|
||||
'ico' => 'left',
|
||||
'value' => 'Retour'
|
||||
|
16
core/module/user/view/import/import.css
vendored
Executable file
@ -0,0 +1,16 @@
|
||||
/**
|
||||
* This file is part of Zwii.
|
||||
*
|
||||
* For full copyright and license information, please see the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*
|
||||
* @author Rémi Jean <remi.jean@outlook.com>
|
||||
* @copyright Copyright (C) 2008-2018, Rémi Jean
|
||||
* @author Frédéric Tempez <frederic.tempez@outlook.com>
|
||||
* @copyright Copyright (C) 2018-2020, Frédéric Tempez
|
||||
* @license GNU General Public License, version 3
|
||||
* @link http://zwiicms.fr/
|
||||
*/
|
||||
|
||||
|
||||
@import url("site/data/admin.css");
|
62
core/module/user/view/import/import.php
Executable file
@ -0,0 +1,62 @@
|
||||
<?php echo template::formOpen('userImportForm'); ?>
|
||||
<div class="row">
|
||||
<div class="col2">
|
||||
<?php echo template::button('userImportBack', [
|
||||
'class' => 'buttonGrey',
|
||||
'href' => helper::baseUrl() . 'user',
|
||||
'ico' => 'left',
|
||||
'value' => 'Retour'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2 offset8">
|
||||
<?php echo template::submit('userImportSubmit', [
|
||||
'value' => 'Importer'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Importation de fichier plat CSV</h4>
|
||||
<div class="row">
|
||||
<div class="col6">
|
||||
<?php echo template::file('userImportCSVFile', [
|
||||
'label' => 'Liste d\'utilisateurs :'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::select('userImportSeparator', $module::$separators, [
|
||||
'label' => 'Séparateur'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<?php echo template::checkbox('userImportNotification', true, 'Envoyer un message de confirmation', [
|
||||
'checked' => false
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col1">
|
||||
<p>Aide :</p>
|
||||
</div>
|
||||
<div class="col11">
|
||||
<p>Les en-têtes obligatoires sont : id, nom, prenom, email et groupe
|
||||
( 1 : membre - 2 : éditeur - 3 : administrateur )
|
||||
<p>Voir ce <a href="core/module/user/ressource/template.csv">modèle</a> à compléter avec un tableur.
|
||||
Enregistrement au format CSV, séparateur ; ou , ou :</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php echo template::formClose(); ?>
|
||||
<?php if ($module::$users): ?>
|
||||
<div class="row">
|
||||
<div class="col12 textAlignCenter">
|
||||
<?php echo template::table([1, 3, 3, 1, 1, 2, 1], $module::$users, ['Id', 'Nom', 'Prénom','Groupe', 'Pseudo', 'eMail', '']); ?>
|
||||
<?php echo template::ico('check');?> Compte créé | <?php echo template::ico('mail');?> Compte créé et notifié | <?php echo template::ico('cancel');?> Erreur dans le fichier, compte non créé.
|
||||
</div>
|
||||
</div>
|
||||
<?php endif;?>
|
@ -7,7 +7,14 @@
|
||||
'value' => 'Accueil'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2 offset8">
|
||||
<div class="col2 offset6">
|
||||
<?php echo template::button('userImport', [
|
||||
'href' => helper::baseUrl() . 'user/import',
|
||||
'ico' => 'plus',
|
||||
'value' => 'Importation'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<?php echo template::button('userAdd', [
|
||||
'href' => helper::baseUrl() . 'user/add',
|
||||
'ico' => 'plus',
|
||||
|
2
core/vendor/filemanager/config/config.php
vendored
@ -119,7 +119,7 @@ $config = array(
|
||||
| If you want to be forced to assign the extension starting from the mime type
|
||||
|
|
||||
*/
|
||||
'mime_extension_rename' => true,
|
||||
'mime_extension_rename' => false,
|
||||
|
||||
|
||||
/*
|
||||
|
986
core/vendor/i18n/css/translateelement.css
vendored
Executable file
@ -0,0 +1,986 @@
|
||||
/* Copyright 2019 Google Inc. All Rights Reserved. */
|
||||
|
||||
body {
|
||||
top: 0px !important;
|
||||
}
|
||||
|
||||
.goog-te-banner-frame {
|
||||
left: 0px;
|
||||
top: -50px !important;
|
||||
height: 39px;
|
||||
width: 100%;
|
||||
z-index: 10000001;
|
||||
position: fixed;
|
||||
border: none !important;
|
||||
border-bottom: 1px solid #6b90da;
|
||||
margin: 0;
|
||||
-moz-box-shadow: 0 0 8px 1px #999999;
|
||||
-webkit-box-shadow: 0 0 8px 1px #999999;
|
||||
box-shadow: 0 0 8px 1px #999999;
|
||||
_position: absolute;
|
||||
}
|
||||
|
||||
.goog-te-menu-frame {
|
||||
z-index: 10000002;
|
||||
position: fixed;
|
||||
border: none;
|
||||
-moz-box-shadow: 0 3px 8px 2px #999999;
|
||||
-webkit-box-shadow: 0 3px 8px 2px #999999;
|
||||
box-shadow: 0 3px 8px 2px #999999;
|
||||
_position: absolute;
|
||||
}
|
||||
|
||||
.goog-te-ftab-frame {
|
||||
z-index: 10000000;
|
||||
border: none;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.goog-te-gadget {
|
||||
font-family: arial;
|
||||
font-size: 0px !important;
|
||||
color: transparent !important;
|
||||
white-space: nowrap;
|
||||
margin-right: 0px !important;
|
||||
margin-top: 2px !important;
|
||||
margin-bottom: 0px !important;
|
||||
width: 160px;
|
||||
margin-left: 15px;
|
||||
padding-right: 5px;
|
||||
}
|
||||
|
||||
.goog-te-gadget img {
|
||||
vertical-align: middle;
|
||||
border: none;
|
||||
}
|
||||
|
||||
.goog-te-gadget-simple {
|
||||
background-color: #fff;
|
||||
border-left: 1px solid #d5d5d5;
|
||||
border-top: 1px solid #9b9b9b;
|
||||
border-bottom: 1px solid #e8e8e8;
|
||||
border-right: 1px solid #d5d5d5;
|
||||
font-size: 10pt;
|
||||
display: inline-block;
|
||||
padding-top: 1px;
|
||||
padding-bottom: 2px;
|
||||
cursor: pointer;
|
||||
zoom: 1;
|
||||
*display: inline;
|
||||
}
|
||||
|
||||
.goog-te-gadget-icon {
|
||||
margin-left: 2px;
|
||||
margin-right: 2px;
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
border: none;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.goog-te-combo {
|
||||
margin-left: 4px;
|
||||
margin-right: 4px;
|
||||
vertical-align: baseline;
|
||||
*vertical-align: middle;
|
||||
}
|
||||
|
||||
.goog-te-gadget .goog-te-combo {
|
||||
margin: 4px 0;
|
||||
margin-left: 4px;
|
||||
background-color: #d8d8d8;
|
||||
}
|
||||
|
||||
.goog-logo-link,
|
||||
.goog-logo-link:link,
|
||||
.goog-logo-link:visited,
|
||||
.goog-logo-link:hover,
|
||||
.goog-logo-link:active {
|
||||
font-size: 12px;
|
||||
font-weight: bold;
|
||||
color: #444;
|
||||
text-decoration: none;
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.goog-te-banner .goog-logo-link,
|
||||
.goog-close-link {
|
||||
display: block;
|
||||
margin: 0px 10px;
|
||||
}
|
||||
|
||||
.goog-te-banner .goog-logo-link {
|
||||
padding-top: 2px;
|
||||
padding-left: 4px;
|
||||
}
|
||||
|
||||
.goog-te-combo,
|
||||
.goog-te-banner *,
|
||||
.goog-te-ftab *,
|
||||
.goog-te-menu *,
|
||||
.goog-te-menu2 *,
|
||||
.goog-te-balloon * {
|
||||
font-family: arial;
|
||||
font-size: 10pt;
|
||||
}
|
||||
|
||||
.goog-te-banner {
|
||||
margin: 0;
|
||||
background-color: #e4effb;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.goog-te-banner img {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.goog-te-banner-content {
|
||||
color: #000;
|
||||
}
|
||||
|
||||
.goog-te-banner-content img {
|
||||
vertical-align: middle
|
||||
}
|
||||
|
||||
.goog-te-banner-info {
|
||||
color: #666;
|
||||
vertical-align: top;
|
||||
margin-top: 0px;
|
||||
font-size: 7pt;
|
||||
}
|
||||
|
||||
.goog-te-banner-margin {
|
||||
width: 8px;
|
||||
}
|
||||
|
||||
.goog-te-button {
|
||||
border-color: #e7e7e7;
|
||||
border-style: none solid solid none;
|
||||
border-width: 0 1px 1px 0;
|
||||
}
|
||||
|
||||
.goog-te-button div {
|
||||
border-color: #cccccc #999999 #999999 #cccccc;
|
||||
border-right: 1px solid #999999;
|
||||
border-style: solid;
|
||||
border-width: 1px;
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
.goog-te-button button {
|
||||
background: transparent;
|
||||
border: none;
|
||||
cursor: pointer;
|
||||
height: 20px;
|
||||
overflow: hidden;
|
||||
margin: 0;
|
||||
vertical-align: top;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.goog-te-button button:active {
|
||||
background: none repeat scroll 0 0 #cccccc;
|
||||
}
|
||||
|
||||
.goog-te-ftab {
|
||||
margin: 0px;
|
||||
background-color: #fff;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.goog-te-ftab-link {
|
||||
text-decoration: none;
|
||||
font-weight: bold;
|
||||
font-size: 10pt;
|
||||
border: 1px outset #888;
|
||||
padding: 6px 10px;
|
||||
white-space: nowrap;
|
||||
position: absolute;
|
||||
left: 0px;
|
||||
top: 0px;
|
||||
}
|
||||
|
||||
.goog-te-ftab-link img {
|
||||
margin-left: 2px;
|
||||
margin-right: 2px;
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
border: none;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.goog-te-ftab-link span {
|
||||
text-decoration: underline;
|
||||
margin-left: 2px;
|
||||
margin-right: 2px;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.goog-float-top .goog-te-ftab-link {
|
||||
padding: 2px 2px;
|
||||
border-top-width: 0px;
|
||||
}
|
||||
|
||||
.goog-float-bottom .goog-te-ftab-link {
|
||||
padding: 2px 2px;
|
||||
border-bottom-width: 0px;
|
||||
}
|
||||
|
||||
.goog-te-menu-value {
|
||||
text-decoration: none;
|
||||
color: #0000cc;
|
||||
white-space: nowrap;
|
||||
margin-left: 4px;
|
||||
margin-right: 4px;
|
||||
}
|
||||
|
||||
.goog-te-menu-value span {
|
||||
text-decoration: underline
|
||||
}
|
||||
|
||||
.goog-te-menu-value img {
|
||||
margin-left: 2px;
|
||||
margin-right: 2px;
|
||||
}
|
||||
|
||||
.goog-te-gadget-simple .goog-te-menu-value {
|
||||
color: #000;
|
||||
}
|
||||
|
||||
.goog-te-gadget-simple .goog-te-menu-value span {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.goog-te-menu {
|
||||
background-color: #ffffff;
|
||||
text-decoration: none;
|
||||
border: 2px solid #c3d9ff;
|
||||
overflow-y: scroll;
|
||||
overflow-x: hidden;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
.goog-te-menu-item {
|
||||
padding: 3px;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.goog-te-menu-item,
|
||||
.goog-te-menu-item:link {
|
||||
color: #0000cc;
|
||||
background: #ffffff;
|
||||
}
|
||||
|
||||
.goog-te-menu-item:visited {
|
||||
color: #551a8b;
|
||||
}
|
||||
|
||||
.goog-te-menu-item:hover {
|
||||
background: #c3d9ff;
|
||||
}
|
||||
|
||||
.goog-te-menu-item:active {
|
||||
color: #0000cc;
|
||||
}
|
||||
|
||||
.goog-te-menu2 {
|
||||
background-color: #ffffff;
|
||||
text-decoration: none;
|
||||
border: 1px solid #6b90da;
|
||||
overflow: hidden;
|
||||
padding: 4px;
|
||||
}
|
||||
|
||||
.goog-te-menu2-colpad {
|
||||
width: 16px;
|
||||
}
|
||||
|
||||
.goog-te-menu2-separator {
|
||||
margin: 6px 0;
|
||||
height: 1px;
|
||||
background-color: #aaa;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.goog-te-menu2-item div,
|
||||
.goog-te-menu2-item-selected div {
|
||||
padding: 4px;
|
||||
}
|
||||
|
||||
.goog-te-menu2-item .indicator {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.goog-te-menu2-item-selected .indicator {
|
||||
display: auto;
|
||||
}
|
||||
|
||||
.goog-te-menu2-item-selected .text {
|
||||
padding-left: 4px;
|
||||
padding-right: 4px;
|
||||
}
|
||||
|
||||
.goog-te-menu2-item,
|
||||
.goog-te-menu2-item-selected {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.goog-te-menu2-item div,
|
||||
.goog-te-menu2-item:link div,
|
||||
.goog-te-menu2-item:visited div,
|
||||
.goog-te-menu2-item:active div {
|
||||
color: #0000cc;
|
||||
background: #ffffff;
|
||||
}
|
||||
|
||||
.goog-te-menu2-item:hover div {
|
||||
color: #ffffff;
|
||||
background: #3366cc;
|
||||
}
|
||||
|
||||
.goog-te-menu2-item-selected div,
|
||||
.goog-te-menu2-item-selected:link div,
|
||||
.goog-te-menu2-item-selected:visited div,
|
||||
.goog-te-menu2-item-selected:hover div,
|
||||
.goog-te-menu2-item-selected:active div {
|
||||
color: #000;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.goog-te-balloon {
|
||||
background-color: #ffffff;
|
||||
overflow: hidden;
|
||||
padding: 8px;
|
||||
border: none;
|
||||
-moz-border-radius: 10px;
|
||||
border-radius: 10px;
|
||||
}
|
||||
|
||||
.goog-te-balloon-frame {
|
||||
background-color: #ffffff;
|
||||
border: 1px solid #6b90da;
|
||||
-moz-box-shadow: 0 3px 8px 2px #999999;
|
||||
-webkit-box-shadow: 0 3px 8px 2px #999999;
|
||||
box-shadow: 0 3px 8px 2px #999999;
|
||||
-moz-border-radius: 8px;
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
.goog-te-balloon img {
|
||||
border: none
|
||||
}
|
||||
|
||||
.goog-te-balloon-text {
|
||||
margin-top: 6px;
|
||||
}
|
||||
|
||||
.goog-te-balloon-zippy {
|
||||
margin-top: 6px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.goog-te-balloon-zippy * {
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.goog-te-balloon-zippy .minus {
|
||||
background-image: url(//www.google.com/images/zippy_minus_sm.gif);
|
||||
}
|
||||
|
||||
.goog-te-balloon-zippy .plus {
|
||||
background-image: url(//www.google.com/images/zippy_plus_sm.gif);
|
||||
}
|
||||
|
||||
.goog-te-balloon-zippy span {
|
||||
color: #00c;
|
||||
text-decoration: underline;
|
||||
cursor: pointer;
|
||||
margin: 0 4px;
|
||||
}
|
||||
|
||||
.goog-te-balloon-form {
|
||||
margin: 6px 0 0 0;
|
||||
}
|
||||
|
||||
.goog-te-balloon-form form {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.goog-te-balloon-form form textarea {
|
||||
margin-bottom: 4px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.goog-te-balloon-footer {
|
||||
margin: 6px 0 4px 0;
|
||||
}
|
||||
|
||||
.goog-te-spinner-pos {
|
||||
z-index: 1000;
|
||||
position: fixed;
|
||||
transition-delay: 0.6s;
|
||||
left: -1000px;
|
||||
top: -1000px;
|
||||
}
|
||||
|
||||
.goog-te-spinner-animation {
|
||||
background: #ccc;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 104px;
|
||||
height: 104px;
|
||||
border-radius: 50px;
|
||||
background: #fff url(//www.gstatic.com/images/branding/product/2x/translate_24dp.png) 50% 50% no-repeat;
|
||||
transition: all 0.6s ease-in-out;
|
||||
transform: scale(0.4);
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
.goog-te-spinner-animation-show {
|
||||
transform: scale(0.5);
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.goog-te-spinner {
|
||||
margin: 2px 0 0 2px;
|
||||
animation: goog-te-spinner-rotator 1.4s linear infinite;
|
||||
}
|
||||
|
||||
@keyframes goog-te-spinner-rotator {
|
||||
0% {
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
transform: rotate(270deg);
|
||||
}
|
||||
}
|
||||
|
||||
.goog-te-spinner-path {
|
||||
stroke-dasharray: 187;
|
||||
stroke-dashoffset: 0;
|
||||
stroke: #4285f4;
|
||||
transform-origin: center;
|
||||
animation: goog-te-spinner-dash 1.4s ease-in-out infinite;
|
||||
}
|
||||
|
||||
@keyframes goog-te-spinner-dash {
|
||||
0% {
|
||||
stroke-dashoffset: 187;
|
||||
}
|
||||
50% {
|
||||
stroke-dashoffset: 46.75;
|
||||
transform: rotate(135deg)
|
||||
}
|
||||
100% {
|
||||
stroke-dashoffset: 187;
|
||||
transform: rotate(450deg)
|
||||
}
|
||||
}
|
||||
|
||||
#goog-gt-tt html,
|
||||
#goog-gt-tt body,
|
||||
#goog-gt-tt div,
|
||||
#goog-gt-tt span,
|
||||
#goog-gt-tt iframe,
|
||||
#goog-gt-tt h1,
|
||||
#goog-gt-tt h2,
|
||||
#goog-gt-tt h3,
|
||||
#goog-gt-tt h4,
|
||||
#goog-gt-tt h5,
|
||||
#goog-gt-tt h6,
|
||||
#goog-gt-tt p,
|
||||
#goog-gt-tt a,
|
||||
#goog-gt-tt img,
|
||||
#goog-gt-tt ol,
|
||||
#goog-gt-tt ul,
|
||||
#goog-gt-tt li,
|
||||
#goog-gt-tt table,
|
||||
#goog-gt-tt form,
|
||||
#goog-gt-tt tbody,
|
||||
#goog-gt-tt tr,
|
||||
#goog-gt-tt td {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
border: 0;
|
||||
font-size: 100%;
|
||||
font: inherit;
|
||||
vertical-align: baseline;
|
||||
text-align: left;
|
||||
line-height: normal;
|
||||
display: none;
|
||||
}
|
||||
|
||||
#goog-gt-tt ol,
|
||||
#goog-gt-tt ul {
|
||||
list-style: none;
|
||||
}
|
||||
|
||||
#goog-gt-tt table {
|
||||
border-collapse: collapse;
|
||||
border-spacing: 0;
|
||||
}
|
||||
|
||||
#goog-gt-tt caption,
|
||||
#goog-gt-tt th,
|
||||
#goog-gt-tt td {
|
||||
text-align: left;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
#goog-gt-tt input::-moz-focus-inner {
|
||||
border: 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#goog-gt-tt .original-text,
|
||||
.gt-hl-layer {
|
||||
clear: both;
|
||||
font-size: 10pt;
|
||||
position: relative;
|
||||
text-align: justify;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#goog-gt-tt .title {
|
||||
color: #999;
|
||||
font-family: arial, sans-serif;
|
||||
margin: 4px 0;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
#goog-gt-tt .close-button {
|
||||
display: none;
|
||||
}
|
||||
|
||||
#goog-gt-tt .logo {
|
||||
float: left;
|
||||
margin: 0px;
|
||||
}
|
||||
|
||||
#goog-gt-tt .activity-links {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
#goog-gt-tt .started-activity-container {
|
||||
display: none;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
#goog-gt-tt .activity-root {
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
#goog-gt-tt .left {
|
||||
float: left;
|
||||
}
|
||||
|
||||
#goog-gt-tt .right {
|
||||
float: right;
|
||||
}
|
||||
|
||||
#goog-gt-tt .bottom {
|
||||
min-height: 15px;
|
||||
position: relative;
|
||||
height: 1%;
|
||||
}
|
||||
|
||||
#goog-gt-tt .status-message {
|
||||
background: -moz-linear-gradient(top, #29910d 0%, #20af0e 100%);
|
||||
background: -webkit-linear-gradient(top, #29910d 0%, #20af0e 100%);
|
||||
background: -o-linear-gradient(top, #29910d 0%, #20af0e 100%);
|
||||
background: -ms-linear-gradient(top, #29910d 0%, #20af0e 100%);
|
||||
background: linear-gradient(top, #29910d 0%, #20af0e 100%);
|
||||
background: #29910d;
|
||||
border-radius: 4px;
|
||||
-moz-border-radius: 4px;
|
||||
-webkit-border-radius: 4px;
|
||||
box-shadow: inset 0px 2px 2px #1e6609;
|
||||
-moz-box-shadow: inset 0px 2px 2px #1e6609;
|
||||
-webkit-box-shadow: inset 0px 2px 2px #1e6609;
|
||||
color: white;
|
||||
font-size: 9pt;
|
||||
font-weight: bolder;
|
||||
margin-top: 12px;
|
||||
padding: 6px;
|
||||
text-shadow: 1px 1px 1px #1e6609;
|
||||
}
|
||||
|
||||
#goog-gt-tt .activity-link {
|
||||
color: #1155cc;
|
||||
cursor: pointer;
|
||||
font-family: arial;
|
||||
font-size: 11px;
|
||||
margin-right: 15px;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
#goog-gt-tt textarea {
|
||||
font-family: arial;
|
||||
resize: vertical;
|
||||
width: 100%;
|
||||
margin-bottom: 10px;
|
||||
-webkit-border-radius: 1px;
|
||||
-moz-border-radius: 1px;
|
||||
border-radius: 1px;
|
||||
border: 1px solid #d9d9d9;
|
||||
border-top: 1px solid silver;
|
||||
font-size: 13px;
|
||||
height: auto;
|
||||
overflow-y: auto;
|
||||
padding: 1px;
|
||||
}
|
||||
|
||||
#goog-gt-tt textarea:focus {
|
||||
-webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.3);
|
||||
-moz-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.3);
|
||||
box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.3);
|
||||
border: 1px solid #4d90fe;
|
||||
outline: none;
|
||||
}
|
||||
|
||||
#goog-gt-tt .activity-cancel {
|
||||
margin-right: 10px;
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form {
|
||||
min-height: 25px;
|
||||
vertical-align: middle;
|
||||
padding-top: 8px;
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form .activity-form {
|
||||
margin-bottom: 5px;
|
||||
margin-bottom: 0px;
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form .activity-form input {
|
||||
display: inline-block;
|
||||
min-width: 54px;
|
||||
*min-width: 70px;
|
||||
border: 1px solid #dcdcdc;
|
||||
border: 1px solid rgba(0, 0, 0, 0.1);
|
||||
text-align: center;
|
||||
color: #444;
|
||||
font-size: 11px;
|
||||
font-weight: bold;
|
||||
height: 27px;
|
||||
outline: 0;
|
||||
padding: 0 8px;
|
||||
vertical-align: middle;
|
||||
line-height: 27px;
|
||||
margin: 0 16px 0 0;
|
||||
box-shadow: 0 1px 2px rgba(0, 0, 0, .1);
|
||||
-moz-box-shadow: 0 1px 2px rgba(0, 0, 0, .1);
|
||||
-webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .1);
|
||||
-webkit-border-radius: 2px;
|
||||
-moz-border-radius: 2px;
|
||||
border-radius: 2px;
|
||||
-webkit-transition: all 0.218s;
|
||||
-moz-transition: all 0.218s;
|
||||
-o-transition: all 0.218s;
|
||||
transition: all 0.218s;
|
||||
background-color: #f5f5f5;
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#f1f1f1));
|
||||
background-image: -webkit-linear-gradient(top, #f5f5f5, #f1f1f1);
|
||||
background-image: -moz-linear-gradient(top, #f5f5f5, #f1f1f1);
|
||||
background-image: -ms-linear-gradient(top, #f5f5f5, #f1f1f1);
|
||||
background-image: -o-linear-gradient(top, #f5f5f5, #f1f1f1);
|
||||
background-image: linear-gradient(top, #f5f5f5, #f1f1f1);
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form .activity-form input:hover {
|
||||
border: 1px solid #c6c6c6;
|
||||
color: #222;
|
||||
-webkit-transition: all 0.0s;
|
||||
-moz-transition: all 0.0s;
|
||||
-o-transition: all 0.0s;
|
||||
transition: all 0.0s;
|
||||
background-color: #f8f8f8;
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f8f8f8), to(#f1f1f1));
|
||||
background-image: -webkit-linear-gradient(top, #f8f8f8, #f1f1f1);
|
||||
background-image: -moz-linear-gradient(top, #f8f8f8, #f1f1f1);
|
||||
background-image: -ms-linear-gradient(top, #f8f8f8, #f1f1f1);
|
||||
background-image: -o-linear-gradient(top, #f8f8f8, #f1f1f1);
|
||||
background-image: linear-gradient(top, #f8f8f8, #f1f1f1);
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form .activity-form input:active {
|
||||
border: 1px solid #c6c6c6;
|
||||
color: #333;
|
||||
background-color: #f6f6f6;
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#f6f6f6), to(#f1f1f1));
|
||||
background-image: -webkit-linear-gradient(top, #f6f6f6, #f1f1f1);
|
||||
background-image: -moz-linear-gradient(top, #f6f6f6, #f1f1f1);
|
||||
background-image: -ms-linear-gradient(top, #f6f6f6, #f1f1f1);
|
||||
background-image: -o-linear-gradient(top, #f6f6f6, #f1f1f1);
|
||||
background-image: linear-gradient(top, #f6f6f6, #f1f1f1);
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form .activity-form input:focus #goog-gt-tt .translate-form .activity-form input.focus #goog-gt-tt .translate-form .activity-form input:active,
|
||||
#goog-gt-tt .translate-form .activity-form input:focus:active,
|
||||
#goog-gt-tt .translate-form .activity-form input:.focus:active {
|
||||
box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
|
||||
-webkit-box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
|
||||
-moz-box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form .activity-form input:focus,
|
||||
#goog-gt-tt .translate-form .activity-form input.focus {
|
||||
outline: none;
|
||||
border: 1px solid #4d90fe;
|
||||
z-index: 4!important;
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form .activity-form input.selected {
|
||||
background-color: #eeeeee;
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#eeeeee), to(#e0e0e0));
|
||||
background-image: -webkit-linear-gradient(top, #eeeeee, #e0e0e0);
|
||||
background-image: -moz-linear-gradient(top, #eeeeee, #e0e0e0);
|
||||
background-image: -ms-linear-gradient(top, #eeeeee, #e0e0e0);
|
||||
background-image: -o-linear-gradient(top, #eeeeee, #e0e0e0);
|
||||
background-image: linear-gradient(top, #eeeeee, #e0e0e0);
|
||||
-webkit-box-shadow: inset 0px 1px 2px rgba(0, 0, 0, 0.1);
|
||||
-moz-box-shadow: inset 0px 1px 2px rgba(0, 0, 0, 0.1);
|
||||
box-shadow: inset 0px 1px 2px rgba(0, 0, 0, 0.1);
|
||||
border: 1px solid #ccc;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form .activity-form input.activity-submit {
|
||||
color: white;
|
||||
border-color: #3079ed;
|
||||
background-color: #4d90fe;
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#4d90fe), to(#4787ed));
|
||||
background-image: -webkit-linear-gradient(top, #4d90fe, #4787ed);
|
||||
background-image: -moz-linear-gradient(top, #4d90fe, #4787ed);
|
||||
background-image: -ms-linear-gradient(top, #4d90fe, #4787ed);
|
||||
background-image: -o-linear-gradient(top, #4d90fe, #4787ed);
|
||||
background-image: linear-gradient(top, #4d90fe, #4787ed);
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form .activity-form input.activity-submit:hover #goog-gt-tt .translate-form .activity-form input.activity-submit:focus,
|
||||
#goog-gt-tt .translate-form .activity-form input.activity-submit.focus #goog-gt-tt .translate-form .activity-form input.activity-submit:active {
|
||||
border-color: #3079ed;
|
||||
background-color: #357ae8;
|
||||
background-image: -webkit-gradient(linear, left top, left bottom, from(#4d90fe), to(#357ae8));
|
||||
background-image: -webkit-linear-gradient(top, #4d90fe, #357ae8);
|
||||
background-image: -moz-linear-gradient(top, #4d90fe, #357ae8);
|
||||
background-image: -ms-linear-gradient(top, #4d90fe, #357ae8);
|
||||
background-image: -o-linear-gradient(top, #4d90fe, #357ae8);
|
||||
background-image: linear-gradient(top, #4d90fe, #357ae8);
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form .activity-form input.activity-submit:hover {
|
||||
box-shadow: inset 0 0 0 1px #fff, 0px 1px 1px rgba(0, 0, 0, 0.1);
|
||||
-webkit-box-shadow: inset 0 0 0 1px #fff, 0px 1px 1px rgba(0, 0, 0, 0.1);
|
||||
-moz-box-shadow: inset 0 0 0 1px #fff, 0px 1px 1px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
#goog-gt-tt .translate-form .activity-form input:focus,
|
||||
#goog-gt-tt .translate-form .activity-form input.focus,
|
||||
#goog-gt-tt .translate-form .activity-form input:active,
|
||||
#goog-gt-tt .translate-form .activity-form input:hover,
|
||||
#goog-gt-tt .translate-form .activity-form input.activity-submit:focus,
|
||||
#goog-gt-tt .translate-form .activity-form input.activity-submit.focus,
|
||||
#goog-gt-tt .translate-form .activity-form input.activity-submit:active,
|
||||
#goog-gt-tt .translate-form .activity-form input.activity-submit:hover {
|
||||
border-color: #3079ed;
|
||||
}
|
||||
|
||||
#goog-gt-tt .gray {
|
||||
color: #999;
|
||||
font-family: arial, sans-serif
|
||||
}
|
||||
|
||||
#goog-gt-tt .alt-helper-text {
|
||||
color: #999;
|
||||
font-size: 11px;
|
||||
font-family: arial, sans-serif;
|
||||
margin: 15px 0px 5px 0px;
|
||||
}
|
||||
|
||||
#goog-gt-tt .alt-error-text {
|
||||
color: #800;
|
||||
display: none;
|
||||
font-size: 9pt;
|
||||
}
|
||||
|
||||
.goog-text-highlight {
|
||||
background-color: #c9d7f1;
|
||||
-webkit-box-shadow: 2px 2px 4px #9999aa;
|
||||
-moz-box-shadow: 2px 2px 4px #9999aa;
|
||||
box-shadow: 2px 2px 4px #9999aa;
|
||||
box-sizing: border-box;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
#goog-gt-tt .alt-menu.goog-menu {
|
||||
background: #ffffff;
|
||||
border: 1px solid #dddddd;
|
||||
-webkit-box-shadow: 0px 3px 3px #888;
|
||||
-moz-box-shadow: 0px 2px 20px #888;
|
||||
box-shadow: 0px 2px 4px #99a;
|
||||
min-width: 0;
|
||||
outline: none;
|
||||
padding: 0;
|
||||
position: absolute;
|
||||
z-index: 2000;
|
||||
}
|
||||
|
||||
#goog-gt-tt .alt-menu .goog-menuitem {
|
||||
cursor: pointer;
|
||||
padding: 2px 5px 5px;
|
||||
margin-right: 0px;
|
||||
border-style: none;
|
||||
}
|
||||
|
||||
#goog-gt-tt .alt-menu div.goog-menuitem:hover {
|
||||
background: #ddd;
|
||||
}
|
||||
|
||||
#goog-gt-tt .alt-menu .goog-menuitem h1 {
|
||||
font-size: 100%;
|
||||
font-weight: bold;
|
||||
margin: 4px 0px;
|
||||
}
|
||||
|
||||
#goog-gt-tt .alt-menu .goog-menuitem strong {
|
||||
color: #345aad
|
||||
}
|
||||
|
||||
#goog-gt-tt .goog-submenu-arrow {
|
||||
text-align: right;
|
||||
position: absolute;
|
||||
right: 0;
|
||||
left: auto;
|
||||
}
|
||||
|
||||
#goog-gt-tt .goog-menuitem-rtl .goog-submenu-arrow {
|
||||
text-align: left;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: auto;
|
||||
}
|
||||
|
||||
#goog-gt-tt .gt-hl-text,
|
||||
#goog-gt-tt .trans-target-highlight {
|
||||
background-color: #f1ea00;
|
||||
border-radius: 4px;
|
||||
-webkit-border-radius: 4px;
|
||||
-moz-border-radius: 4px;
|
||||
-moz-box-shadow: rgba(0, 0, 0, .5) 3px 3px 4px;
|
||||
-webkit-box-shadow: rgba(0, 0, 0, .5) 3px 3px 4px;
|
||||
box-shadow: rgba(0, 0, 0, .5) 3px 3px 4px;
|
||||
box-sizing: border-box;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
color: #f1ea00;
|
||||
cursor: pointer;
|
||||
margin: -2px -2px -2px -3px;
|
||||
padding: 2px 2px 2px 3px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
#goog-gt-tt .trans-target-highlight {
|
||||
color: #222;
|
||||
}
|
||||
|
||||
#goog-gt-tt .gt-hl-layer {
|
||||
color: white;
|
||||
position: absolute!important;
|
||||
}
|
||||
|
||||
#goog-gt-tt .trans-target,
|
||||
#goog-gt-tt .trans-target .trans-target-highlight {
|
||||
background-color: #c9d7f1;
|
||||
border-radius: 4px 4px 0px 0px;
|
||||
-webkit-border-radius: 4px 4px 0px 0px;
|
||||
-moz-border-radius: 4px 4px 0px 0px;
|
||||
-moz-box-shadow: rgba(0, 0, 0, .5) 3px 3px 4px;
|
||||
-webkit-box-shadow: rgba(0, 0, 0, .5) 3px 3px 4px;
|
||||
box-shadow: rgba(0, 0, 0, .5) 3px 3px 4px;
|
||||
box-sizing: border-box;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
cursor: pointer;
|
||||
margin: -2px -2px -2px -3px;
|
||||
padding: 2px 2px 3px 3px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
#goog-gt-tt span:focus {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
#goog-gt-tt .trans-edit {
|
||||
background-color: transparent;
|
||||
border: 1px solid #4d90fe;
|
||||
border-radius: 0em;
|
||||
-webkit-border-radius: 0em;
|
||||
-moz-border-radius: 0em;
|
||||
margin: -2px;
|
||||
padding: 1px;
|
||||
}
|
||||
|
||||
#goog-gt-tt .gt-trans-highlight-l {
|
||||
border-left: 2px solid red;
|
||||
margin-left: -2px
|
||||
}
|
||||
|
||||
#goog-gt-tt .gt-trans-highlight-r {
|
||||
border-right: 2px solid red;
|
||||
margin-right: -2px;
|
||||
}
|
||||
|
||||
#goog-gt-tt #alt-input {
|
||||
padding: 2px;
|
||||
}
|
||||
|
||||
#goog-gt-tt #alt-input-text {
|
||||
font-size: 11px;
|
||||
padding: 2px 2px 3px;
|
||||
margin: 0;
|
||||
background-color: #fff;
|
||||
color: #333;
|
||||
border: 1px solid #d9d9d9;
|
||||
border-top: 1px solid #c0c0c0;
|
||||
display: inline-block;
|
||||
vertical-align: top;
|
||||
height: 21px;
|
||||
box-sizing: border-box;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
-webkit-border-radius: 1px;
|
||||
}
|
||||
|
||||
#goog-gt-tt #alt-input-text:hover {
|
||||
border: 1px solid #b9b9b9;
|
||||
border-top: 1px solid #a0a0a0;
|
||||
-webkit-box-shadow: inset 0px 1px 2px rgba(0, 0, 0, 0.1);
|
||||
-moz-box-shadow: inset 0px 1px 2px rgba(0, 0, 0, 0.1);
|
||||
box-shadow: inset 0px 1px 2px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
#goog-gt-tt #alt-input-text:focus {
|
||||
-webkit-box-shadow: inset 0px 1px 2px rgba(0, 0, 0, 0.3);
|
||||
-moz-box-shadow: inset 0px 1px 2px rgba(0, 0, 0, 0.3);
|
||||
box-shadow: inset 0px 1px 2px rgba(0, 0, 0, 0.3);
|
||||
outline: none;
|
||||
border: 1px solid #4d90fe;
|
||||
}
|
||||
|
||||
#goog-gt-tt #alt-input-submit {
|
||||
font-size: 11px;
|
||||
padding: 2px 6px 3px;
|
||||
margin: 0 0 0 2px;
|
||||
height: 21px;
|
||||
}
|
5
core/vendor/i18n/inc.json
vendored
Executable file
@ -0,0 +1,5 @@
|
||||
[
|
||||
"translate.js",
|
||||
"translation.js",
|
||||
"css/translateelement.css"
|
||||
]
|
BIN
core/vendor/i18n/png/de.png
vendored
Normal file
After Width: | Height: | Size: 119 B |
BIN
core/vendor/i18n/png/en.png
vendored
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
core/vendor/i18n/png/es.png
vendored
Normal file
After Width: | Height: | Size: 287 B |
BIN
core/vendor/i18n/png/fr.png
vendored
Normal file
After Width: | Height: | Size: 96 B |
BIN
core/vendor/i18n/png/it.png
vendored
Normal file
After Width: | Height: | Size: 96 B |
BIN
core/vendor/i18n/png/nl.png
vendored
Normal file
After Width: | Height: | Size: 108 B |
BIN
core/vendor/i18n/png/pt.png
vendored
Normal file
After Width: | Height: | Size: 395 B |
68
core/vendor/i18n/translate.js
vendored
Executable file
@ -0,0 +1,68 @@
|
||||
(function () {
|
||||
var gtConstEvalStartTime = new Date();
|
||||
|
||||
function d(b) {
|
||||
var a = document.getElementsByTagName("head")[0];
|
||||
a || (a = document.body.parentNode.appendChild(document.createElement("head")));
|
||||
a.appendChild(b)
|
||||
}
|
||||
|
||||
function _loadJs(b) {
|
||||
var a = document.createElement("script");
|
||||
a.type = "text/javascript";
|
||||
a.charset = "UTF-8";
|
||||
a.src = b;
|
||||
d(a)
|
||||
}
|
||||
|
||||
function _loadCss(b) {
|
||||
var a = document.createElement("link");
|
||||
a.type = "text/css";
|
||||
a.rel = "stylesheet";
|
||||
a.charset = "UTF-8";
|
||||
a.href = b;
|
||||
d(a)
|
||||
}
|
||||
|
||||
function _isNS(b) {
|
||||
b = b.split(".");
|
||||
for (var a = window, c = 0; c < b.length; ++c)
|
||||
if (!(a = a[b[c]])) return !1;
|
||||
return !0
|
||||
}
|
||||
|
||||
function _setupNS(b) {
|
||||
b = b.split(".");
|
||||
for (var a = window, c = 0; c < b.length; ++c) a.hasOwnProperty ? a.hasOwnProperty(b[c]) ? a = a[b[c]] : a = a[b[c]] = {} : a = a[b[c]] || (a[b[c]] = {});
|
||||
return a
|
||||
}
|
||||
window.addEventListener && "undefined" == typeof document.readyState && window.addEventListener("DOMContentLoaded", function () {
|
||||
document.readyState = "complete"
|
||||
}, !1);
|
||||
if (_isNS('google.translate.Element')) {
|
||||
return
|
||||
}(function () {
|
||||
var c = _setupNS('google.translate._const');
|
||||
c._cest = gtConstEvalStartTime;
|
||||
gtConstEvalStartTime = undefined;
|
||||
c._cl = 'fr';
|
||||
c._cuc = 'scriptGoogleElementInit';
|
||||
c._cac = '';
|
||||
c._cam = '';
|
||||
c._ctkk = '433074.3898829376';
|
||||
var h = 'translate.googleapis.com';
|
||||
var s = (true ? 'https' : window.location.protocol == 'https:' ? 'https' : 'http') + '://';
|
||||
var b = s + h;
|
||||
c._pah = h;
|
||||
c._pas = s;
|
||||
c._pbi = b + '/translate_static/img/te_bk.gif';
|
||||
c._pci = b + '/translate_static/img/te_ctrl3.gif';
|
||||
c._pli = b + '/translate_static/img/loading.gif';
|
||||
c._plla = h + '/translate_a/l';
|
||||
c._pmi = b + '/translate_static/img/mini_google.png';
|
||||
c._ps = b + '/translate_static/css/translateelement.css';
|
||||
c._puh = 'translate.google.com';
|
||||
_loadCss(c._ps);
|
||||
_loadJs(b + '/translate_static/js/element/main_fr.js');
|
||||
})();
|
||||
})();
|
5
core/vendor/i18n/translation.js
vendored
Executable file
@ -0,0 +1,5 @@
|
||||
function scriptGoogleElementInit() {
|
||||
new google.translate.TranslateElement({
|
||||
pageLanguage: 'fr'
|
||||
}, 'google_translate_element');
|
||||
}
|
4
core/vendor/tinymce/inc.json
vendored
@ -2,7 +2,5 @@
|
||||
"tinymce.min.js",
|
||||
"jquery.tinymce.min.js",
|
||||
"init.js",
|
||||
"init.css",
|
||||
"plugins/codesample/js/prism.fr",
|
||||
"plugins/codesample/css/prism.css"
|
||||
"init.css"
|
||||
]
|
158
core/vendor/tinymce/init.js
vendored
@ -4,6 +4,13 @@
|
||||
|
||||
*/
|
||||
|
||||
/**
|
||||
* Quand tinyMCE est invoqué hors connexion, initialiser privateKey
|
||||
*/
|
||||
if ( typeof(privateKey) == 'undefined') {
|
||||
var privateKey = null;
|
||||
};
|
||||
|
||||
tinymce.init({
|
||||
// Classe où appliquer l'éditeur
|
||||
selector: ".editorWysiwyg",
|
||||
@ -28,12 +35,6 @@ tinymce.init({
|
||||
char: "🤯"
|
||||
}
|
||||
},
|
||||
// Autoriser tous les éléments
|
||||
valid_elements : '*[*]',
|
||||
// Autorise l'ajout de script
|
||||
extended_valid_elements: "script[language|type|src]",
|
||||
// Conserver les styles
|
||||
keep_styles: false,
|
||||
// CodeMirror
|
||||
codemirror: {
|
||||
indentOnInit: true, // Whether or not to indent code on init.
|
||||
@ -103,8 +104,12 @@ tinymce.init({
|
||||
images_dataimg_filter: function(img) {
|
||||
return img.hasAttribute('internal-blob');
|
||||
},*/
|
||||
// Autoriser tous les éléments
|
||||
valid_elements : '*[*]',
|
||||
// Autorise l'ajout de script
|
||||
// extended_valid_elements: "script[language|type|src]",
|
||||
extended_valid_elements: "script[language|type|src]",
|
||||
// Conserver les styles
|
||||
keep_styles: false,
|
||||
// Bloque le dimensionnement des médias (car automatiquement en fullsize avec fitvids pour le responsive)
|
||||
media_dimensions: true,
|
||||
// Désactiver la dimension des images
|
||||
@ -121,12 +126,6 @@ tinymce.init({
|
||||
external_plugins: {
|
||||
"filemanager": baseUrl + "core/vendor/filemanager/plugin.min.js"
|
||||
},
|
||||
// Thème mobile
|
||||
// mobile: {
|
||||
// theme: "mobile",
|
||||
// plugins: [ 'autosave', 'lists', 'autolink' ],
|
||||
// toolbar: [ 'undo', 'bold', 'italic', 'styleselect' ]
|
||||
//},
|
||||
// Contenu du bouton insérer
|
||||
insert_button_items: "anchor hr table",
|
||||
// Contenu du bouton formats
|
||||
@ -209,6 +208,139 @@ tinymce.init({
|
||||
]
|
||||
});
|
||||
|
||||
|
||||
tinymce.init({
|
||||
// Classe où appliquer l'éditeur
|
||||
selector: ".editorWysiwygComment",
|
||||
setup:function(ed) {
|
||||
// Aperçu dans le pied de page
|
||||
ed.on('change', function(e) {
|
||||
if (ed.id === 'themeFooterText') {
|
||||
$("#footerText").html(tinyMCE.get('themeFooterText').getContent());
|
||||
}
|
||||
});
|
||||
// Limitation du nombre de caractères des commentaires à maxlength
|
||||
var alarmCaraMin = 200; // alarme sur le nombre de caractères restants à partir de...
|
||||
var maxlength = parseInt($("#" + (ed.id)).attr("maxlength"));
|
||||
var id_alarm = "#blogArticleContentAlarm"
|
||||
var contentLength = 0;
|
||||
ed.on("keydown", function(e) {
|
||||
contentLength = ed.getContent({format : 'text'}).length;
|
||||
if (contentLength > maxlength) {
|
||||
$(id_alarm).html("Vous avez atteint le maximum de " + maxlength + " caractères ! ");
|
||||
if(e.keyCode != 8 && e.keyCode != 46){
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
else{
|
||||
if(maxlength - contentLength < alarmCaraMin){
|
||||
$(id_alarm).html((maxlength - contentLength) + " caractères restants");
|
||||
}
|
||||
else{
|
||||
$(id_alarm).html(" ");
|
||||
}
|
||||
}
|
||||
});
|
||||
// Limitation y compris lors d'un copier/coller
|
||||
ed.on("paste", function(e){
|
||||
contentLeng = ed.getContent({format : 'text'}).length - 16;
|
||||
var data = e.clipboardData.getData('Text');
|
||||
if (data.length > (maxlength - contentLeng)) {
|
||||
$(id_alarm).html("Vous alliez dépasser le maximum de " + maxlength + " caractères ! ");
|
||||
return false;
|
||||
} else {
|
||||
if(maxlength - contentLeng < alarmCaraMin){
|
||||
$(id_alarm).html((maxlength - contentLeng - data.length) + " caractères restants");
|
||||
}
|
||||
else{
|
||||
$(id_alarm).html(" ");
|
||||
}
|
||||
return true;
|
||||
}
|
||||
});
|
||||
},
|
||||
// Langue
|
||||
language: "fr_FR",
|
||||
// Plugins
|
||||
plugins: "advlist anchor autolink autoresize autosave colorpicker contextmenu fullscreen hr lists paste searchreplace stickytoolbar tabfocus template textcolor visualblocks emoticons",
|
||||
// Contenu de la barre d'outils
|
||||
toolbar: "restoredraft | undo redo | formatselect bold italic forecolor backcolor | alignleft aligncenter alignright alignjustify | bullist numlist emoticons | visualblocks fullscreen",
|
||||
// Emoticons
|
||||
emoticons_append: {
|
||||
custom_mind_explode: {
|
||||
keywords: ["brain", "mind", "explode", "blown"],
|
||||
char: "🤯"
|
||||
}
|
||||
},
|
||||
// Titre des images
|
||||
image_title: true,
|
||||
// Pages internes
|
||||
link_list: baseUrl + "core/vendor/tinymce/links.php",
|
||||
// Contenu du menu contextuel
|
||||
contextmenu: "cut copy paste pastetext | selectall searchreplace ",
|
||||
// Fichiers CSS à intégrer à l'éditeur
|
||||
content_css: [
|
||||
baseUrl + "core/layout/common.css",
|
||||
baseUrl + "core/vendor/tinymce/content.css",
|
||||
baseUrl + "site/data/theme.css",
|
||||
baseUrl + "site/data/custom.css"
|
||||
],
|
||||
// Classe à ajouter à la balise body dans l'iframe
|
||||
body_class: "editorWysiwyg",
|
||||
// Cache les menus
|
||||
menubar: false,
|
||||
// URL menu contextuel
|
||||
link_context_toolbar: true,
|
||||
// Cache la barre de statut
|
||||
statusbar: false,
|
||||
// Autorise le copié collé à partir du web
|
||||
paste_data_images: true,
|
||||
// Bloque le dimensionnement des médias (car automatiquement en fullsize avec fitvids pour le responsive)
|
||||
media_dimensions: true,
|
||||
// Désactiver la dimension des images
|
||||
image_dimensions: true,
|
||||
// Active l'onglet avancé lors de l'ajout d'une image
|
||||
image_advtab: true,
|
||||
// Urls absolues
|
||||
relative_urls: false,
|
||||
// Url de base
|
||||
document_base_url: baseUrl,
|
||||
// Contenu du bouton formats
|
||||
style_formats: [
|
||||
{title: "Headers", items: [
|
||||
{title: "Header 1", format: "h1"},
|
||||
{title: "Header 2", format: "h2"},
|
||||
{title: "Header 3", format: "h3"},
|
||||
{title: "Header 4", format: "h4"}
|
||||
]},
|
||||
{title: "Inline", items: [
|
||||
{title: "Bold", icon: "bold", format: "bold"},
|
||||
{title: "Italic", icon: "italic", format: "italic"},
|
||||
{title: "Underline", icon: "underline", format: "underline"},
|
||||
{title: "Strikethrough", icon: "strikethrough", format: "strikethrough"},
|
||||
{title: "Superscript", icon: "superscript", format: "superscript"},
|
||||
{title: "Subscript", icon: "subscript", format: "subscript"},
|
||||
{title: "Code", icon: "code", format: "code"}
|
||||
]},
|
||||
{title: "Blocks", items: [
|
||||
{title: "Paragraph", format: "p"},
|
||||
{title: "Blockquote", format: "blockquote"},
|
||||
{title: "Div", format: "div"},
|
||||
{title: "Pre", format: "pre"}
|
||||
]},
|
||||
{title: "Alignment", items: [
|
||||
{title: "Left", icon: "alignleft", format: "alignleft"},
|
||||
{title: "Center", icon: "aligncenter", format: "aligncenter"},
|
||||
{title: "Right", icon: "alignright", format: "alignright"},
|
||||
{title: "Justify", icon: "alignjustify", format: "alignjustify"}
|
||||
]}
|
||||
]
|
||||
});
|
||||
|
||||
|
||||
|
||||
tinymce.PluginManager.add('stickytoolbar', function(editor, url) {
|
||||
editor.on('init', function() {
|
||||
setSticky();
|
||||
|
138
core/vendor/tinymce/plugins/codesample/css/prism.css
vendored
@ -1,138 +0,0 @@
|
||||
/* http://prismjs.com/download.html?themes=prism&languages=markup+css+clike+javascript */
|
||||
/**
|
||||
* prism.js default theme for JavaScript, CSS and HTML
|
||||
* Based on dabblet (http://dabblet.com)
|
||||
* @author Lea Verou
|
||||
*/
|
||||
|
||||
code[class*="language-"],
|
||||
pre[class*="language-"] {
|
||||
color: black;
|
||||
text-shadow: 0 1px white;
|
||||
font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
|
||||
direction: ltr;
|
||||
text-align: left;
|
||||
white-space: pre;
|
||||
word-spacing: normal;
|
||||
word-break: normal;
|
||||
word-wrap: normal;
|
||||
line-height: 1.5;
|
||||
|
||||
-moz-tab-size: 4;
|
||||
-o-tab-size: 4;
|
||||
tab-size: 4;
|
||||
|
||||
-webkit-hyphens: none;
|
||||
-moz-hyphens: none;
|
||||
-ms-hyphens: none;
|
||||
hyphens: none;
|
||||
}
|
||||
|
||||
pre[class*="language-"]::-moz-selection, pre[class*="language-"] ::-moz-selection,
|
||||
code[class*="language-"]::-moz-selection, code[class*="language-"] ::-moz-selection {
|
||||
text-shadow: none;
|
||||
background: #b3d4fc;
|
||||
}
|
||||
|
||||
pre[class*="language-"]::selection, pre[class*="language-"] ::selection,
|
||||
code[class*="language-"]::selection, code[class*="language-"] ::selection {
|
||||
text-shadow: none;
|
||||
background: #b3d4fc;
|
||||
}
|
||||
|
||||
@media print {
|
||||
code[class*="language-"],
|
||||
pre[class*="language-"] {
|
||||
text-shadow: none;
|
||||
}
|
||||
}
|
||||
|
||||
/* Code blocks */
|
||||
pre[class*="language-"] {
|
||||
padding: 1em;
|
||||
margin: .5em 0;
|
||||
overflow: auto;
|
||||
}
|
||||
|
||||
:not(pre) > code[class*="language-"],
|
||||
pre[class*="language-"] {
|
||||
background: #f5f2f0;
|
||||
}
|
||||
|
||||
/* Inline code */
|
||||
:not(pre) > code[class*="language-"] {
|
||||
padding: .1em;
|
||||
border-radius: .3em;
|
||||
}
|
||||
|
||||
.token.comment,
|
||||
.token.prolog,
|
||||
.token.doctype,
|
||||
.token.cdata {
|
||||
color: slategray;
|
||||
}
|
||||
|
||||
.token.punctuation {
|
||||
color: #999;
|
||||
}
|
||||
|
||||
.namespace {
|
||||
opacity: .7;
|
||||
}
|
||||
|
||||
.token.property,
|
||||
.token.tag,
|
||||
.token.boolean,
|
||||
.token.number,
|
||||
.token.constant,
|
||||
.token.symbol,
|
||||
.token.deleted {
|
||||
color: #905;
|
||||
}
|
||||
|
||||
.token.selector,
|
||||
.token.attr-name,
|
||||
.token.string,
|
||||
.token.char,
|
||||
.token.builtin,
|
||||
.token.inserted {
|
||||
color: #690;
|
||||
}
|
||||
|
||||
.token.operator,
|
||||
.token.entity,
|
||||
.token.url,
|
||||
.language-css .token.string,
|
||||
.style .token.string {
|
||||
color: #a67f59;
|
||||
background: hsla(0, 0%, 100%, .5);
|
||||
}
|
||||
|
||||
.token.atrule,
|
||||
.token.attr-value,
|
||||
.token.keyword {
|
||||
color: #07a;
|
||||
}
|
||||
|
||||
.token.function {
|
||||
color: #DD4A68;
|
||||
}
|
||||
|
||||
.token.regex,
|
||||
.token.important,
|
||||
.token.variable {
|
||||
color: #e90;
|
||||
}
|
||||
|
||||
.token.important,
|
||||
.token.bold {
|
||||
font-weight: bold;
|
||||
}
|
||||
.token.italic {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.token.entity {
|
||||
cursor: help;
|
||||
}
|
||||
|
44
core/vendor/zwiico/css/zwiico-codes.css
vendored
@ -1,50 +1,54 @@
|
||||
|
||||
.zwiico-plus-circled:before { content: '\2191'; } /* '↑' */
|
||||
.zwiico-flag:before { content: '\2691'; } /* '⚑' */
|
||||
.zwiico-mail:before { content: '\2709'; } /* '✉' */
|
||||
.zwiico-divide:before { content: '\e05b'; } /* '' */
|
||||
.zwiico-logout:before { content: '\e800'; } /* '' */
|
||||
.zwiico-check:before { content: '\e801'; } /* '' */
|
||||
.zwiico-plus:before { content: '\e801'; } /* '' */
|
||||
.zwiico-cancel:before { content: '\e802'; } /* '' */
|
||||
.zwiico-plus:before { content: '\e803'; } /* '' */
|
||||
.zwiico-help:before { content: '\e803'; } /* '' */
|
||||
.zwiico-minus:before { content: '\e804'; } /* '' */
|
||||
.zwiico-help:before { content: '\e805'; } /* '' */
|
||||
.zwiico-gear:before { content: '\e805'; } /* '' */
|
||||
.zwiico-pencil:before { content: '\e806'; } /* '' */
|
||||
.zwiico-gear:before { content: '\e807'; } /* '' */
|
||||
.zwiico-up:before { content: '\e807'; } /* '' */
|
||||
.zwiico-eye:before { content: '\e808'; } /* '' */
|
||||
.zwiico-up:before { content: '\e809'; } /* '' */
|
||||
.zwiico-download:before { content: '\e809'; } /* '' */
|
||||
.zwiico-folder:before { content: '\e80a'; } /* '' */
|
||||
.zwiico-download:before { content: '\e80b'; } /* '' */
|
||||
.zwiico-users:before { content: '\e80b'; } /* '' */
|
||||
.zwiico-left:before { content: '\e80c'; } /* '' */
|
||||
.zwiico-users:before { content: '\e80d'; } /* '' */
|
||||
.zwiico-user:before { content: '\e80e'; } /* '' */
|
||||
.zwiico-comment:before { content: '\e80f'; } /* '' */
|
||||
.zwiico-update:before { content: '\e80f'; } /* '' */
|
||||
.zwiico-home:before { content: '\e810'; } /* '' */
|
||||
.zwiico-mimi:before { content: '\e811'; } /* '' */
|
||||
.zwiico-trash:before { content: '\e811'; } /* '' */
|
||||
.zwiico-down:before { content: '\e812'; } /* '' */
|
||||
.zwiico-lock:before { content: '\e813'; } /* '' */
|
||||
.zwiico-comment:before { content: '\e813'; } /* '' */
|
||||
.zwiico-chat:before { content: '\e814'; } /* '' */
|
||||
.zwiico-eye-off:before { content: '\e815'; } /* '' */
|
||||
.zwiico-update:before { content: '\e816'; } /* '' */
|
||||
.zwiico-down-open:before { content: '\e816'; } /* '' */
|
||||
.zwiico-upload:before { content: '\e817'; } /* '' */
|
||||
.zwiico-down-open:before { content: '\e818'; } /* '' */
|
||||
.zwiico-cogs:before { content: '\e818'; } /* '' */
|
||||
.zwiico-left-open:before { content: '\e819'; } /* '' */
|
||||
.zwiico-cogs:before { content: '\e81a'; } /* '' */
|
||||
.zwiico-down-big:before { content: '\e81a'; } /* '' */
|
||||
.zwiico-cog-alt:before { content: '\e81b'; } /* '' */
|
||||
.zwiico-trash:before { content: '\e81c'; } /* '' */
|
||||
.zwiico-plus-circled:before { content: '\e81d'; } /* '' */
|
||||
.zwiico-up-big:before { content: '\e81c'; } /* '' */
|
||||
.zwiico-clone:before { content: '\e81d'; } /* '' */
|
||||
.zwiico-minus-circled:before { content: '\e81e'; } /* '' */
|
||||
.zwiico-login:before { content: '\e81f'; } /* '' */
|
||||
.zwiico-down-big:before { content: '\e820'; } /* '' */
|
||||
.zwiico-up-big:before { content: '\e821'; } /* '' */
|
||||
.zwiico-check:before { content: '\e81f'; } /* '' */
|
||||
.zwiico-github:before { content: '\e820'; } /* '' */
|
||||
.zwiico-login:before { content: '\e821'; } /* '' */
|
||||
.zwiico-lock:before { content: '\e822'; } /* '' */
|
||||
.zwiico-mimi:before { content: '\e823'; } /* '' */
|
||||
.zwiico-spin:before { content: '\e831'; } /* '' */
|
||||
.zwiico-twitter:before { content: '\f099'; } /* '' */
|
||||
.zwiico-facebook:before { content: '\f09a'; } /* '' */
|
||||
.zwiico-menu:before { content: '\f0c9'; } /* '' */
|
||||
.zwiico-sort:before { content: '\f0dc'; } /* '' */
|
||||
.zwiico-mail-alt:before { content: '\f0e0'; } /* '' */
|
||||
.zwiico-linkedin:before { content: '\f0e1'; } /* '' */
|
||||
.zwiico-download-cloud:before { content: '\f0ed'; } /* '' */
|
||||
.zwiico-upload-cloud:before { content: '\f0ee'; } /* '' */
|
||||
.zwiico-github:before { content: '\f113'; } /* '' */
|
||||
.zwiico-code:before { content: '\f121'; } /* '' */
|
||||
.zwiico-youtube:before { content: '\f167'; } /* '' */
|
||||
.zwiico-instagram:before { content: '\f16d'; } /* '' */
|
||||
.zwiico-brush:before { content: '\f1fc'; } /* '' */
|
||||
.zwiico-pinterest:before { content: '\f231'; } /* '' */
|
||||
.zwiico-clone:before { content: '\f24d'; } /* '' */
|
60
core/vendor/zwiico/css/zwiico-embedded.css
vendored
44
core/vendor/zwiico/css/zwiico-ie7-codes.css
vendored
@ -1,50 +1,54 @@
|
||||
|
||||
.zwiico-plus-circled { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = '↑ '); }
|
||||
.zwiico-flag { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = '⚑ '); }
|
||||
.zwiico-mail { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = '✉ '); }
|
||||
.zwiico-divide { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-logout { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-check { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-plus { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-cancel { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-plus { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-help { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-minus { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-help { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-gear { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-pencil { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-gear { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-up { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-eye { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-up { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-download { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-folder { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-download { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-users { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-left { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-users { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-user { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-comment { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-update { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-home { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-mimi { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-trash { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-down { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-lock { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-comment { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-chat { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-eye-off { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-update { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-down-open { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-upload { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-down-open { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-cogs { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-left-open { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-cogs { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-down-big { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-cog-alt { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-trash { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-plus-circled { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-up-big { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-clone { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-minus-circled { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-login { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-down-big { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-up-big { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-check { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-github { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-login { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-lock { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-mimi { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-spin { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-twitter { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-facebook { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-menu { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-sort { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-mail-alt { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-linkedin { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-download-cloud { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-upload-cloud { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-github { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-code { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-youtube { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-instagram { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-brush { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-pinterest { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-clone { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
44
core/vendor/zwiico/css/zwiico-ie7.css
vendored
@ -10,52 +10,56 @@
|
||||
/* font-size: 120%; */
|
||||
}
|
||||
|
||||
.zwiico-plus-circled { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = '↑ '); }
|
||||
.zwiico-flag { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = '⚑ '); }
|
||||
.zwiico-mail { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = '✉ '); }
|
||||
.zwiico-divide { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-logout { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-check { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-plus { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-cancel { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-plus { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-help { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-minus { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-help { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-gear { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-pencil { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-gear { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-up { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-eye { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-up { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-download { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-folder { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-download { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-users { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-left { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-users { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-user { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-comment { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-update { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-home { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-mimi { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-trash { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-down { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-lock { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-comment { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-chat { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-eye-off { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-update { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-down-open { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-upload { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-down-open { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-cogs { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-left-open { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-cogs { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-down-big { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-cog-alt { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-trash { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-plus-circled { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-up-big { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-clone { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-minus-circled { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-login { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-down-big { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-up-big { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-check { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-github { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-login { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-lock { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-mimi { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-spin { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-twitter { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-facebook { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-menu { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-sort { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-mail-alt { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-linkedin { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-download-cloud { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-upload-cloud { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-github { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-code { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-youtube { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-instagram { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-brush { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-pinterest { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
||||
.zwiico-clone { *zoom: expression( this.runtimeStyle['zoom'] = '1', this.innerHTML = ' '); }
|
58
core/vendor/zwiico/css/zwiico.css
vendored
@ -1,11 +1,11 @@
|
||||
@font-face {
|
||||
font-family: 'zwiico';
|
||||
src: url('../font/zwiico.eot?21777250');
|
||||
src: url('../font/zwiico.eot?21777250#iefix') format('embedded-opentype'),
|
||||
url('../font/zwiico.woff2?21777250') format('woff2'),
|
||||
url('../font/zwiico.woff?21777250') format('woff'),
|
||||
url('../font/zwiico.ttf?21777250') format('truetype'),
|
||||
url('../font/zwiico.svg?21777250#zwiico') format('svg');
|
||||
src: url('../font/zwiico.eot?96515118');
|
||||
src: url('../font/zwiico.eot?96515118#iefix') format('embedded-opentype'),
|
||||
url('../font/zwiico.woff2?96515118') format('woff2'),
|
||||
url('../font/zwiico.woff?96515118') format('woff'),
|
||||
url('../font/zwiico.ttf?96515118') format('truetype'),
|
||||
url('../font/zwiico.svg?96515118#zwiico') format('svg');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
@ -15,7 +15,7 @@
|
||||
@media screen and (-webkit-min-device-pixel-ratio:0) {
|
||||
@font-face {
|
||||
font-family: 'zwiico';
|
||||
src: url('../font/zwiico.svg?21777250#zwiico') format('svg');
|
||||
src: url('../font/zwiico.svg?96515118#zwiico') format('svg');
|
||||
}
|
||||
}
|
||||
*/
|
||||
@ -55,52 +55,56 @@
|
||||
/* text-shadow: 1px 1px 1px rgba(127, 127, 127, 0.3); */
|
||||
}
|
||||
|
||||
.zwiico-plus-circled:before { content: '\2191'; } /* '↑' */
|
||||
.zwiico-flag:before { content: '\2691'; } /* '⚑' */
|
||||
.zwiico-mail:before { content: '\2709'; } /* '✉' */
|
||||
.zwiico-divide:before { content: '\e05b'; } /* '' */
|
||||
.zwiico-logout:before { content: '\e800'; } /* '' */
|
||||
.zwiico-check:before { content: '\e801'; } /* '' */
|
||||
.zwiico-plus:before { content: '\e801'; } /* '' */
|
||||
.zwiico-cancel:before { content: '\e802'; } /* '' */
|
||||
.zwiico-plus:before { content: '\e803'; } /* '' */
|
||||
.zwiico-help:before { content: '\e803'; } /* '' */
|
||||
.zwiico-minus:before { content: '\e804'; } /* '' */
|
||||
.zwiico-help:before { content: '\e805'; } /* '' */
|
||||
.zwiico-gear:before { content: '\e805'; } /* '' */
|
||||
.zwiico-pencil:before { content: '\e806'; } /* '' */
|
||||
.zwiico-gear:before { content: '\e807'; } /* '' */
|
||||
.zwiico-up:before { content: '\e807'; } /* '' */
|
||||
.zwiico-eye:before { content: '\e808'; } /* '' */
|
||||
.zwiico-up:before { content: '\e809'; } /* '' */
|
||||
.zwiico-download:before { content: '\e809'; } /* '' */
|
||||
.zwiico-folder:before { content: '\e80a'; } /* '' */
|
||||
.zwiico-download:before { content: '\e80b'; } /* '' */
|
||||
.zwiico-users:before { content: '\e80b'; } /* '' */
|
||||
.zwiico-left:before { content: '\e80c'; } /* '' */
|
||||
.zwiico-users:before { content: '\e80d'; } /* '' */
|
||||
.zwiico-user:before { content: '\e80e'; } /* '' */
|
||||
.zwiico-comment:before { content: '\e80f'; } /* '' */
|
||||
.zwiico-update:before { content: '\e80f'; } /* '' */
|
||||
.zwiico-home:before { content: '\e810'; } /* '' */
|
||||
.zwiico-mimi:before { content: '\e811'; } /* '' */
|
||||
.zwiico-trash:before { content: '\e811'; } /* '' */
|
||||
.zwiico-down:before { content: '\e812'; } /* '' */
|
||||
.zwiico-lock:before { content: '\e813'; } /* '' */
|
||||
.zwiico-comment:before { content: '\e813'; } /* '' */
|
||||
.zwiico-chat:before { content: '\e814'; } /* '' */
|
||||
.zwiico-eye-off:before { content: '\e815'; } /* '' */
|
||||
.zwiico-update:before { content: '\e816'; } /* '' */
|
||||
.zwiico-down-open:before { content: '\e816'; } /* '' */
|
||||
.zwiico-upload:before { content: '\e817'; } /* '' */
|
||||
.zwiico-down-open:before { content: '\e818'; } /* '' */
|
||||
.zwiico-cogs:before { content: '\e818'; } /* '' */
|
||||
.zwiico-left-open:before { content: '\e819'; } /* '' */
|
||||
.zwiico-cogs:before { content: '\e81a'; } /* '' */
|
||||
.zwiico-down-big:before { content: '\e81a'; } /* '' */
|
||||
.zwiico-cog-alt:before { content: '\e81b'; } /* '' */
|
||||
.zwiico-trash:before { content: '\e81c'; } /* '' */
|
||||
.zwiico-plus-circled:before { content: '\e81d'; } /* '' */
|
||||
.zwiico-up-big:before { content: '\e81c'; } /* '' */
|
||||
.zwiico-clone:before { content: '\e81d'; } /* '' */
|
||||
.zwiico-minus-circled:before { content: '\e81e'; } /* '' */
|
||||
.zwiico-login:before { content: '\e81f'; } /* '' */
|
||||
.zwiico-down-big:before { content: '\e820'; } /* '' */
|
||||
.zwiico-up-big:before { content: '\e821'; } /* '' */
|
||||
.zwiico-check:before { content: '\e81f'; } /* '' */
|
||||
.zwiico-github:before { content: '\e820'; } /* '' */
|
||||
.zwiico-login:before { content: '\e821'; } /* '' */
|
||||
.zwiico-lock:before { content: '\e822'; } /* '' */
|
||||
.zwiico-mimi:before { content: '\e823'; } /* '' */
|
||||
.zwiico-spin:before { content: '\e831'; } /* '' */
|
||||
.zwiico-twitter:before { content: '\f099'; } /* '' */
|
||||
.zwiico-facebook:before { content: '\f09a'; } /* '' */
|
||||
.zwiico-menu:before { content: '\f0c9'; } /* '' */
|
||||
.zwiico-sort:before { content: '\f0dc'; } /* '' */
|
||||
.zwiico-mail-alt:before { content: '\f0e0'; } /* '' */
|
||||
.zwiico-linkedin:before { content: '\f0e1'; } /* '' */
|
||||
.zwiico-download-cloud:before { content: '\f0ed'; } /* '' */
|
||||
.zwiico-upload-cloud:before { content: '\f0ee'; } /* '' */
|
||||
.zwiico-github:before { content: '\f113'; } /* '' */
|
||||
.zwiico-code:before { content: '\f121'; } /* '' */
|
||||
.zwiico-youtube:before { content: '\f167'; } /* '' */
|
||||
.zwiico-instagram:before { content: '\f16d'; } /* '' */
|
||||
.zwiico-brush:before { content: '\f1fc'; } /* '' */
|
||||
.zwiico-pinterest:before { content: '\f231'; } /* '' */
|
||||
.zwiico-clone:before { content: '\f24d'; } /* '' */
|
BIN
core/vendor/zwiico/font/zwiico.eot
vendored
54
core/vendor/zwiico/font/zwiico.svg
vendored
@ -6,73 +6,83 @@
|
||||
<font id="zwiico" horiz-adv-x="1000" >
|
||||
<font-face font-family="zwiico" font-weight="400" font-stretch="normal" units-per-em="1000" ascent="850" descent="-150" />
|
||||
<missing-glyph horiz-adv-x="1000" />
|
||||
<glyph glyph-name="plus-circled" unicode="↑" d="M420 770q174 0 297-123t123-297-123-297-297-123-297 123-123 297 123 297 297 123z m52-470l200 0 0 102-200 0 0 202-102 0 0-202-202 0 0-102 202 0 0-202 102 0 0 202z" horiz-adv-x="840" />
|
||||
|
||||
<glyph glyph-name="flag" unicode="⚑" d="M179 707q0-40-36-61v-707q0-7-5-12t-13-6h-36q-7 0-12 6t-6 12v707q-35 21-35 61 0 30 21 51t50 21 51-21 21-51z m821-36v-425q0-14-7-22t-22-15q-120-65-206-65-34 0-69 12t-60 27-65 27-79 12q-107 0-259-81-10-5-19-5-14 0-25 10t-10 25v415q0 17 17 30 12 8 44 24 132 67 235 67 60 0 112-16t122-49q21-11 49-11 30 0 65 12t62 26 49 26 30 12q15 0 25-10t11-26z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="mail" unicode="✉" d="M929 11v428q-18-20-39-36-149-115-238-189-28-24-46-37t-48-28-57-13h-2q-26 0-57 13t-48 28-46 37q-88 74-238 189-21 16-39 36v-428q0-7 6-13t12-5h822q7 0 12 5t6 13z m0 586v14t-1 7-1 7-3 5-5 4-8 2h-822q-7 0-12-6t-6-12q0-94 83-159 107-84 223-176 4-3 20-17t25-21 25-17 28-16 24-5h2q11 0 24 5t28 16 25 17 25 21 20 17q116 92 224 176 30 24 56 65t26 73z m71 21v-607q0-37-26-63t-63-27h-822q-36 0-63 27t-26 63v607q0 37 26 63t63 26h822q37 0 63-26t26-63z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="divide" unicode="" d="M300 663q0 117 116 117 118 0 118-117t-118-118q-116 0-116 118z m0-625q0 117 116 117 118 0 118-117t-118-118q-116 0-116 118z m-300 312q0 43 30 73t74 31l625 0q44 0 74-31t31-73-31-73-74-31l-625 0q-44 0-74 31t-30 73z" horiz-adv-x="834" />
|
||||
|
||||
<glyph glyph-name="logout" unicode="" d="M357 46q0-2 1-11t0-14-2-14-5-11-12-3h-178q-67 0-114 47t-47 114v392q0 67 47 114t114 47h178q8 0 13-5t5-13q0-2 1-11t0-15-2-13-5-11-12-3h-178q-37 0-63-26t-27-64v-392q0-37 27-63t63-27h174t6 0 7-2 4-3 4-5 1-8z m518 304q0-14-11-25l-303-304q-11-10-25-10t-25 10-11 25v161h-250q-14 0-25 11t-11 25v214q0 15 11 25t25 11h250v161q0 14 11 25t25 10 25-10l303-304q11-10 11-25z" horiz-adv-x="928.6" />
|
||||
|
||||
<glyph glyph-name="check" unicode="" d="M933 534q0-22-16-38l-404-404-76-76q-16-15-38-15t-38 15l-76 76-202 202q-15 16-15 38t15 38l76 76q16 16 38 16t38-16l164-165 366 367q16 16 38 16t38-16l76-76q16-15 16-38z" horiz-adv-x="1000" />
|
||||
<glyph glyph-name="plus" unicode="" d="M786 439v-107q0-22-16-38t-38-15h-232v-233q0-22-16-37t-38-16h-107q-22 0-38 16t-15 37v233h-232q-23 0-38 15t-16 38v107q0 23 16 38t38 16h232v232q0 22 15 38t38 16h107q23 0 38-16t16-38v-232h232q23 0 38-16t16-38z" horiz-adv-x="785.7" />
|
||||
|
||||
<glyph glyph-name="cancel" unicode="" d="M724 112q0-22-15-38l-76-76q-16-15-38-15t-38 15l-164 165-164-165q-16-15-38-15t-38 15l-76 76q-16 16-16 38t16 38l164 164-164 164q-16 16-16 38t16 38l76 76q16 16 38 16t38-16l164-164 164 164q16 16 38 16t38-16l76-76q15-15 15-38t-15-38l-164-164 164-164q15-15 15-38z" horiz-adv-x="785.7" />
|
||||
|
||||
<glyph glyph-name="plus" unicode="" d="M786 439v-107q0-22-16-38t-38-15h-232v-233q0-22-16-37t-38-16h-107q-22 0-38 16t-15 37v233h-232q-23 0-38 15t-16 38v107q0 23 16 38t38 16h232v232q0 22 15 38t38 16h107q23 0 38-16t16-38v-232h232q23 0 38-16t16-38z" horiz-adv-x="785.7" />
|
||||
<glyph glyph-name="help" unicode="" d="M500 82v107q0 8-5 13t-13 5h-107q-8 0-13-5t-5-13v-107q0-8 5-13t13-5h107q8 0 13 5t5 13z m143 375q0 49-31 91t-77 65-95 23q-136 0-207-119-9-13 4-24l74-55q4-4 10-4 9 0 14 7 30 38 48 51 19 14 48 14 27 0 48-15t21-33q0-21-11-34t-38-25q-35-15-65-48t-29-70v-20q0-8 5-13t13-5h107q8 0 13 5t5 13q0 10 12 27t30 28q18 10 28 16t25 19 25 27 16 34 7 45z m214-107q0-117-57-215t-156-156-215-58-216 58-155 156-58 215 58 215 155 156 216 58 215-58 156-156 57-215z" horiz-adv-x="857.1" />
|
||||
|
||||
<glyph glyph-name="minus" unicode="" d="M786 439v-107q0-22-16-38t-38-15h-678q-23 0-38 15t-16 38v107q0 23 16 38t38 16h678q23 0 38-16t16-38z" horiz-adv-x="785.7" />
|
||||
|
||||
<glyph glyph-name="help" unicode="" d="M500 82v107q0 8-5 13t-13 5h-107q-8 0-13-5t-5-13v-107q0-8 5-13t13-5h107q8 0 13 5t5 13z m143 375q0 49-31 91t-77 65-95 23q-136 0-207-119-9-13 4-24l74-55q4-4 10-4 9 0 14 7 30 38 48 51 19 14 48 14 27 0 48-15t21-33q0-21-11-34t-38-25q-35-15-65-48t-29-70v-20q0-8 5-13t13-5h107q8 0 13 5t5 13q0 10 12 27t30 28q18 10 28 16t25 19 25 27 16 34 7 45z m214-107q0-117-57-215t-156-156-215-58-216 58-155 156-58 215 58 215 155 156 216 58 215-58 156-156 57-215z" horiz-adv-x="857.1" />
|
||||
<glyph glyph-name="gear" unicode="" d="M571 350q0 59-41 101t-101 42-101-42-42-101 42-101 101-42 101 42 41 101z m286 61v-124q0-7-4-13t-11-7l-104-16q-10-30-21-51 19-27 59-77 6-6 6-13t-5-13q-15-21-55-61t-53-39q-7 0-14 5l-77 60q-25-13-51-21-9-76-16-104-4-16-20-16h-124q-8 0-14 5t-6 12l-16 103q-27 9-50 21l-79-60q-6-5-14-5-8 0-14 6-70 64-92 94-4 5-4 13 0 6 5 12 8 12 28 37t30 40q-15 28-23 55l-102 15q-7 1-11 7t-5 13v124q0 7 5 13t10 7l104 16q8 25 22 51-23 32-60 77-6 7-6 14 0 5 5 12 15 20 55 60t53 40q7 0 15-5l77-60q24 13 50 21 9 76 17 104 3 16 20 16h124q7 0 13-5t7-12l15-103q28-9 51-20l79 59q5 5 13 5 7 0 14-5 72-67 92-95 4-5 4-12 0-7-4-13-9-12-29-37t-30-40q15-28 23-54l102-16q7-1 12-7t4-13z" horiz-adv-x="857.1" />
|
||||
|
||||
<glyph glyph-name="pencil" unicode="" d="M203-7l50 51-131 131-51-51v-60h72v-71h60z m291 518q0 12-12 12-5 0-9-4l-303-302q-4-4-4-10 0-12 13-12 5 0 9 4l303 302q3 4 3 10z m-30 107l232-232-464-465h-232v233z m381-54q0-29-20-50l-93-93-232 233 93 92q20 21 50 21 29 0 51-21l131-131q20-22 20-51z" horiz-adv-x="857.1" />
|
||||
|
||||
<glyph glyph-name="gear" unicode="" d="M571 350q0 59-41 101t-101 42-101-42-42-101 42-101 101-42 101 42 41 101z m286 61v-124q0-7-4-13t-11-7l-104-16q-10-30-21-51 19-27 59-77 6-6 6-13t-5-13q-15-21-55-61t-53-39q-7 0-14 5l-77 60q-25-13-51-21-9-76-16-104-4-16-20-16h-124q-8 0-14 5t-6 12l-16 103q-27 9-50 21l-79-60q-6-5-14-5-8 0-14 6-70 64-92 94-4 5-4 13 0 6 5 12 8 12 28 37t30 40q-15 28-23 55l-102 15q-7 1-11 7t-5 13v124q0 7 5 13t10 7l104 16q8 25 22 51-23 32-60 77-6 7-6 14 0 5 5 12 15 20 55 60t53 40q7 0 15-5l77-60q24 13 50 21 9 76 17 104 3 16 20 16h124q7 0 13-5t7-12l15-103q28-9 51-20l79 59q5 5 13 5 7 0 14-5 72-67 92-95 4-5 4-12 0-7-4-13-9-12-29-37t-30-40q15-28 23-54l102-16q7-1 12-7t4-13z" horiz-adv-x="857.1" />
|
||||
<glyph glyph-name="up" unicode="" d="M939 107l-92-92q-11-10-26-10t-25 10l-296 297-296-297q-11-10-25-10t-25 10l-93 92q-11 11-11 26t11 25l414 414q11 10 25 10t25-10l414-414q11-11 11-25t-11-26z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="eye" unicode="" d="M929 314q-85 132-213 197 34-58 34-125 0-103-73-177t-177-73-177 73-73 177q0 67 34 125-128-65-213-197 75-114 187-182t242-68 243 68 186 182z m-402 215q0 11-8 19t-19 7q-70 0-120-50t-50-119q0-11 8-19t19-8 19 8 8 19q0 48 34 82t82 34q11 0 19 8t8 19z m473-215q0-19-11-38-78-129-210-206t-279-77-279 77-210 206q-11 19-11 38t11 39q78 128 210 205t279 78 279-78 210-205q11-20 11-39z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="up" unicode="" d="M939 107l-92-92q-11-10-26-10t-25 10l-296 297-296-297q-11-10-25-10t-25 10l-93 92q-11 11-11 26t11 25l414 414q11 10 25 10t25-10l414-414q11-11 11-25t-11-26z" horiz-adv-x="1000" />
|
||||
<glyph glyph-name="download" unicode="" d="M714 100q0 15-10 25t-25 11-25-11-11-25 11-25 25-11 25 11 10 25z m143 0q0 15-10 25t-26 11-25-11-10-25 10-25 25-11 26 11 10 25z m72 125v-179q0-22-16-37t-38-16h-821q-23 0-38 16t-16 37v179q0 22 16 38t38 16h259l75-76q33-32 76-32t76 32l76 76h259q22 0 38-16t16-38z m-182 318q10-23-8-39l-250-250q-10-11-25-11t-25 11l-250 250q-17 16-8 39 10 21 33 21h143v250q0 15 11 25t25 11h143q14 0 25-11t10-25v-250h143q24 0 33-21z" horiz-adv-x="928.6" />
|
||||
|
||||
<glyph glyph-name="folder" unicode="" d="M1049 319q0-17-18-37l-187-221q-24-28-67-48t-81-20h-607q-19 0-33 7t-15 24q0 17 17 37l188 221q24 28 67 48t80 20h607q19 0 34-7t15-24z m-192 192v-90h-464q-53 0-110-26t-92-67l-188-221-2-3q0 2-1 7t0 7v536q0 51 37 88t88 37h179q51 0 88-37t37-88v-18h303q52 0 88-37t37-88z" horiz-adv-x="1071.4" />
|
||||
|
||||
<glyph glyph-name="download" unicode="" d="M714 100q0 15-10 25t-25 11-25-11-11-25 11-25 25-11 25 11 10 25z m143 0q0 15-10 25t-26 11-25-11-10-25 10-25 25-11 26 11 10 25z m72 125v-179q0-22-16-37t-38-16h-821q-23 0-38 16t-16 37v179q0 22 16 38t38 16h259l75-76q33-32 76-32t76 32l76 76h259q22 0 38-16t16-38z m-182 318q10-23-8-39l-250-250q-10-11-25-11t-25 11l-250 250q-17 16-8 39 10 21 33 21h143v250q0 15 11 25t25 11h143q14 0 25-11t10-25v-250h143q24 0 33-21z" horiz-adv-x="928.6" />
|
||||
<glyph glyph-name="users" unicode="" d="M331 350q-90-3-148-71h-75q-45 0-77 22t-31 66q0 197 69 197 4 0 25-11t54-24 66-12q38 0 75 13-3-21-3-37 0-78 45-143z m598-356q0-66-41-105t-108-39h-488q-68 0-108 39t-41 105q0 30 2 58t8 61 14 61 24 54 35 45 48 30 62 11q6 0 24-12t41-26 59-27 76-12 75 12 60 27 41 26 24 12q34 0 62-11t47-30 35-45 24-54 15-61 8-61 2-58z m-572 713q0-59-42-101t-101-42-101 42-42 101 42 101 101 42 101-42 42-101z m393-214q0-89-63-152t-151-62-152 62-63 152 63 151 152 63 151-63 63-151z m321-126q0-43-31-66t-77-22h-75q-57 68-147 71 45 65 45 143 0 16-3 37 37-13 74-13 33 0 67 12t54 24 24 11q69 0 69-197z m-71 340q0-59-42-101t-101-42-101 42-42 101 42 101 101 42 101-42 42-101z" horiz-adv-x="1071.4" />
|
||||
|
||||
<glyph glyph-name="left" unicode="" d="M357 600v-500q0-14-10-25t-26-11-25 11l-250 250q-10 11-10 25t10 25l250 250q11 11 25 11t26-11 10-25z" horiz-adv-x="357.1" />
|
||||
|
||||
<glyph glyph-name="users" unicode="" d="M331 350q-90-3-148-71h-75q-45 0-77 22t-31 66q0 197 69 197 4 0 25-11t54-24 66-12q38 0 75 13-3-21-3-37 0-78 45-143z m598-356q0-66-41-105t-108-39h-488q-68 0-108 39t-41 105q0 30 2 58t8 61 14 61 24 54 35 45 48 30 62 11q6 0 24-12t41-26 59-27 76-12 75 12 60 27 41 26 24 12q34 0 62-11t47-30 35-45 24-54 15-61 8-61 2-58z m-572 713q0-59-42-101t-101-42-101 42-42 101 42 101 101 42 101-42 42-101z m393-214q0-89-63-152t-151-62-152 62-63 152 63 151 152 63 151-63 63-151z m321-126q0-43-31-66t-77-22h-75q-57 68-147 71 45 65 45 143 0 16-3 37 37-13 74-13 33 0 67 12t54 24 24 11q69 0 69-197z m-71 340q0-59-42-101t-101-42-101 42-42 101 42 101 101 42 101-42 42-101z" horiz-adv-x="1071.4" />
|
||||
|
||||
<glyph glyph-name="user" unicode="" d="M714 69q0-60-35-104t-84-44h-476q-49 0-84 44t-35 104q0 48 5 90t17 85 33 73 52 50 76 19q73-72 174-72t175 72q42 0 75-19t52-50 33-73 18-85 4-90z m-143 495q0-88-62-151t-152-63-151 63-63 151 63 152 151 63 152-63 62-152z" horiz-adv-x="714.3" />
|
||||
|
||||
<glyph glyph-name="comment" unicode="" d="M0 96l0 713 1000 0 0-713-473 0-320-205 0 205-207 0z" horiz-adv-x="1000" />
|
||||
<glyph glyph-name="update" unicode="" d="M843 261q0-3 0-4-36-150-150-243t-267-93q-81 0-157 31t-136 88l-72-72q-11-11-25-11t-25 11-11 25v250q0 14 11 25t25 11h250q14 0 25-11t10-25-10-25l-77-77q40-36 90-57t105-20q74 0 139 37t104 99q6 10 30 66 4 13 16 13h107q8 0 13-6t5-12z m14 446v-250q0-14-10-25t-26-11h-250q-14 0-25 11t-10 25 10 25l77 77q-82 77-194 77-75 0-140-37t-104-99q-6-10-29-66-5-13-17-13h-111q-7 0-13 6t-5 12v4q36 150 151 243t268 93q81 0 158-31t137-88l72 72q11 11 25 11t26-11 10-25z" horiz-adv-x="857.1" />
|
||||
|
||||
<glyph glyph-name="home" unicode="" d="M786 296v-267q0-15-11-25t-25-11h-214v214h-143v-214h-214q-15 0-25 11t-11 25v267q0 1 0 2t0 2l321 264 321-264q1-1 1-4z m124 39l-34-41q-5-5-12-6h-2q-7 0-12 3l-386 322-386-322q-7-4-13-3-7 1-12 6l-35 41q-4 6-3 13t6 12l401 334q18 15 42 15t43-15l136-113v108q0 8 5 13t13 5h107q8 0 13-5t5-13v-227l122-102q6-4 6-12t-4-13z" horiz-adv-x="928.6" />
|
||||
|
||||
<glyph glyph-name="mimi" unicode="" d="M909 286c0-241-203-436-454-436s-455 195-455 436 204 564 455 564 454-324 454-564z m-454 396c-141 0-255-114-255-254s114-255 255-255 254 114 254 255-114 254-254 254z m91-254c0-51-41-91-91-91s-91 40-91 91 40 90 91 90 91-40 91-90z" horiz-adv-x="909" />
|
||||
<glyph glyph-name="trash" unicode="" d="M50 458q122-70 330-70t330 70l-54-486q-2-14-35-36t-100-43-141-21-140 21-100 43-36 36z m488 300q94-18 158-55t64-71l0-10q0-58-112-99t-268-41-268 41-112 99l0 10q0 34 64 71t158 55l42 48q22 26 70 26l92 0q52 0 70-26z m-54-112l84 0q-92 110-104 126-14 16-32 16l-102 0q-22 0-32-16l-106-126 84 0 64 66 82 0z" horiz-adv-x="760" />
|
||||
|
||||
<glyph glyph-name="down" unicode="" d="M571 457q0-14-10-25l-250-250q-11-11-25-11t-25 11l-250 250q-11 11-11 25t11 25 25 11h500q14 0 25-11t10-25z" horiz-adv-x="571.4" />
|
||||
|
||||
<glyph glyph-name="lock" unicode="" d="M179 421h285v108q0 59-42 101t-101 41-101-41-41-101v-108z m464-53v-322q0-22-16-37t-38-16h-535q-23 0-38 16t-16 37v322q0 22 16 38t38 15h17v108q0 102 74 176t176 74 177-74 73-176v-108h18q23 0 38-15t16-38z" horiz-adv-x="642.9" />
|
||||
<glyph glyph-name="comment" unicode="" d="M0 96l0 713 1000 0 0-713-473 0-320-205 0 205-207 0z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="chat" unicode="" d="M786 421q0-77-53-143t-143-104-197-38q-48 0-98 9-70-49-155-72-21-5-48-9h-2q-6 0-12 5t-6 12q-1 1-1 3t1 4 1 3l1 3t2 3 2 3 3 3 2 2q3 3 13 14t15 16 12 17 14 21 11 25q-69 40-108 98t-40 125q0 78 53 144t143 104 197 38 197-38 143-104 53-144z m214-142q0-67-40-126t-108-98q5-14 11-25t14-21 13-16 14-17 13-14q0 0 2-2t3-3 2-3 2-3l1-3t1-3 1-4-1-3q-2-8-7-13t-12-4q-28 4-48 9-86 23-156 72-50-9-98-9-151 0-263 74 32-3 49-3 90 0 172 25t148 72q69 52 107 119t37 141q0 43-13 85 72-39 114-99t42-128z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="eye-off" unicode="" d="M310 105l43 79q-48 35-76 88t-27 114q0 67 34 125-128-65-213-197 94-144 239-209z m217 424q0 11-8 19t-19 7q-70 0-120-50t-50-119q0-11 8-19t19-8 19 8 8 19q0 48 34 82t82 34q11 0 19 8t8 19z m202 106q0-4 0-5-59-105-176-316t-176-316l-28-50q-5-9-15-9-7 0-75 39-9 6-9 16 0 7 25 49-80 36-147 96t-117 137q-11 17-11 38t11 39q86 131 212 207t277 76q50 0 100-10l31 54q5 9 15 9 3 0 10-3t18-9 18-10 18-10 10-7q9-5 9-15z m21-249q0-78-44-142t-117-91l157 280q4-25 4-47z m250-72q0-19-11-38-22-36-61-81-84-96-194-149t-234-53l41 74q119 10 219 76t169 171q-65 100-158 164l35 63q53-36 102-85t81-103q11-19 11-39z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="update" unicode="" d="M843 261q0-3 0-4-36-150-150-243t-267-93q-81 0-157 31t-136 88l-72-72q-11-11-25-11t-25 11-11 25v250q0 14 11 25t25 11h250q14 0 25-11t10-25-10-25l-77-77q40-36 90-57t105-20q74 0 139 37t104 99q6 10 30 66 4 13 16 13h107q8 0 13-6t5-12z m14 446v-250q0-14-10-25t-26-11h-250q-14 0-25 11t-10 25 10 25l77 77q-82 77-194 77-75 0-140-37t-104-99q-6-10-29-66-5-13-17-13h-111q-7 0-13 6t-5 12v4q36 150 151 243t268 93q81 0 158-31t137-88l72 72q11 11 25 11t26-11 10-25z" horiz-adv-x="857.1" />
|
||||
<glyph glyph-name="down-open" unicode="" d="M939 399l-414-413q-10-11-25-11t-25 11l-414 413q-11 11-11 26t11 25l93 92q10 11 25 11t25-11l296-296 296 296q11 11 25 11t26-11l92-92q11-11 11-25t-11-26z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="upload" unicode="" d="M714 29q0 14-10 25t-25 10-25-10-11-25 11-25 25-11 25 11 10 25z m143 0q0 14-10 25t-26 10-25-10-10-25 10-25 25-11 26 11 10 25z m72 125v-179q0-22-16-38t-38-16h-821q-23 0-38 16t-16 38v179q0 22 16 38t38 15h238q12-31 39-51t62-20h143q34 0 61 20t40 51h238q22 0 38-15t16-38z m-182 361q-9-22-33-22h-143v-250q0-15-10-25t-25-11h-143q-15 0-25 11t-11 25v250h-143q-23 0-33 22-9 22 8 39l250 250q10 10 25 10t25-10l250-250q18-17 8-39z" horiz-adv-x="928.6" />
|
||||
|
||||
<glyph glyph-name="down-open" unicode="" d="M939 399l-414-413q-10-11-25-11t-25 11l-414 413q-11 11-11 26t11 25l93 92q10 11 25 11t25-11l296-296 296 296q11 11 25 11t26-11l92-92q11-11 11-25t-11-26z" horiz-adv-x="1000" />
|
||||
<glyph glyph-name="cogs" unicode="" d="M0 245l0 97 94 8q8 30 23 55l-60 74 68 69 74-61q26 16 55 23l8 94 97 0 10-94q29-7 55-23l74 61 68-69-60-74q16-25 23-55l94-8 0-97-94-10q-7-29-23-55l60-72-68-70-74 60q-26-15-55-23l-10-94-97 0-8 94q-29 8-55 23l-74-60-68 70 60 72q-15 26-23 55z m221 49q0-37 26-64t64-26 63 26 26 64-26 63-63 26-64-26-26-63z m318 238l8 72 70-2q8 22 20 39l-37 57 54 45 49-49q20 10 41 14l14 66 72-8-2-68q22-8 39-22l57 39 45-54-49-49q10-20 12-43l68-14-8-70-68 0q-8-20-22-37l39-59-56-45-47 49q-22-8-43-12l-14-66-70 6 0 70q-20 8-37 20l-59-37-45 54 49 49q-8 20-12 41z m31-445l6 50 49 0q6 16 14 28l-26 43 37 33 36-37q13 8 29 10l10 48 48-5 0-49q16-6 28-16l41 27 31-41-35-35q6-13 10-29l47-12-6-51-49 0q-4-15-14-27l28-43-40-33-35 37q-13-8-29-10l-10-49-49 6 0 51q-13 4-27 14l-41-28-31 41 35 36q-6 13-8 29z m118 13q-4-21 8-36t32-17 34 9 17 34-10 35-31 18l-6 0q-17 0-31-12t-13-31z m17 451q-4-27 14-48t45-25 48 15 23 45-14 48-44 24l-7 0q-26 0-44-17t-21-42z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="left-open" unicode="" d="M654 682l-297-296 297-297q10-10 10-25t-10-25l-93-93q-11-10-25-10t-25 10l-414 415q-11 10-11 25t11 25l414 414q10 11 25 11t25-11l93-93q10-10 10-25t-10-25z" horiz-adv-x="714.3" />
|
||||
|
||||
<glyph glyph-name="cogs" unicode="" d="M0 245l0 97 94 8q8 30 23 55l-60 74 68 69 74-61q26 16 55 23l8 94 97 0 10-94q29-7 55-23l74 61 68-69-60-74q16-25 23-55l94-8 0-97-94-10q-7-29-23-55l60-72-68-70-74 60q-26-15-55-23l-10-94-97 0-8 94q-29 8-55 23l-74-60-68 70 60 72q-15 26-23 55z m221 49q0-37 26-64t64-26 63 26 26 64-26 63-63 26-64-26-26-63z m318 238l8 72 70-2q8 22 20 39l-37 57 54 45 49-49q20 10 41 14l14 66 72-8-2-68q22-8 39-22l57 39 45-54-49-49q10-20 12-43l68-14-8-70-68 0q-8-20-22-37l39-59-56-45-47 49q-22-8-43-12l-14-66-70 6 0 70q-20 8-37 20l-59-37-45 54 49 49q-8 20-12 41z m31-445l6 50 49 0q6 16 14 28l-26 43 37 33 36-37q13 8 29 10l10 48 48-5 0-49q16-6 28-16l41 27 31-41-35-35q6-13 10-29l47-12-6-51-49 0q-4-15-14-27l28-43-40-33-35 37q-13-8-29-10l-10-49-49 6 0 51q-13 4-27 14l-41-28-31 41 35 36q-6 13-8 29z m118 13q-4-21 8-36t32-17 34 9 17 34-10 35-31 18l-6 0q-17 0-31-12t-13-31z m17 451q-4-27 14-48t45-25 48 15 23 45-14 48-44 24l-7 0q-26 0-44-17t-21-42z" horiz-adv-x="1000" />
|
||||
<glyph glyph-name="down-big" unicode="" d="M899 386q0-30-21-50l-363-364q-22-21-51-21-29 0-50 21l-363 364q-21 20-21 50 0 29 21 51l41 41q22 21 51 21 29 0 50-21l164-164v393q0 29 21 50t51 22h71q29 0 50-22t21-50v-393l165 164q20 21 50 21 29 0 51-21l41-41q21-22 21-51z" horiz-adv-x="928.6" />
|
||||
|
||||
<glyph glyph-name="cog-alt" unicode="" d="M500 350q0 59-42 101t-101 42-101-42-42-101 42-101 101-42 101 42 42 101z m429-286q0 29-22 51t-50 21-50-21-21-51q0-29 21-50t50-21 51 21 21 50z m0 572q0 29-22 50t-50 21-50-21-21-50q0-30 21-51t50-21 51 21 21 51z m-215-235v-103q0-6-4-11t-8-6l-87-14q-6-19-18-42 19-27 50-64 4-6 4-11 0-7-4-11-12-17-46-50t-43-33q-7 0-12 4l-64 50q-21-11-43-17-6-60-13-87-4-13-17-13h-104q-6 0-11 4t-5 10l-13 85q-19 6-42 18l-66-50q-4-4-11-4-6 0-12 4-80 75-80 90 0 5 4 10 5 8 23 30t26 34q-13 24-20 46l-85 13q-5 1-9 5t-4 11v104q0 5 4 10t9 6l86 14q7 19 18 42-19 27-50 64-4 6-4 11 0 7 4 12 12 16 46 49t44 33q6 0 12-4l64-50q19 10 43 18 6 60 13 86 3 13 16 13h104q6 0 11-4t6-10l13-85q19-6 42-17l65 49q5 4 12 4 6 0 11-4 81-75 81-90 0-4-4-10-7-9-24-30t-25-34q13-27 19-46l85-12q6-2 9-6t4-11z m357-298v-78q0-9-83-17-6-15-16-29 28-63 28-77 0-2-2-4-68-40-69-40-5 0-26 27t-29 37q-11-1-17-1t-17 1q-7-11-29-37t-25-27q-1 0-69 40-3 2-3 4 0 14 29 77-10 14-17 29-83 8-83 17v78q0 9 83 18 7 16 17 29-29 63-29 77 0 2 3 4 2 1 19 11t33 19 17 9q4 0 25-26t29-38q12 1 17 1t17-1q28 40 51 63l4 1q2 0 69-39 2-2 2-4 0-14-28-77 9-13 16-29 83-9 83-18z m0 572v-78q0-9-83-18-6-15-16-29 28-63 28-77 0-2-2-4-68-39-69-39-5 0-26 26t-29 38q-11-1-17-1t-17 1q-7-12-29-38t-25-26q-1 0-69 39-3 2-3 4 0 14 29 77-10 14-17 29-83 9-83 18v78q0 9 83 17 7 16 17 29-29 63-29 77 0 2 3 4 2 1 19 11t33 19 17 9q4 0 25-26t29-37q12 1 17 1t17-1q28 39 51 62l4 1q2 0 69-39 2-2 2-4 0-14-28-77 9-13 16-29 83-8 83-17z" horiz-adv-x="1071.4" />
|
||||
|
||||
<glyph glyph-name="trash" unicode="" d="M50 458q122-70 330-70t330 70l-54-486q-2-14-35-36t-100-43-141-21-140 21-100 43-36 36z m488 300q94-18 158-55t64-71l0-10q0-58-112-99t-268-41-268 41-112 99l0 10q0 34 64 71t158 55l42 48q22 26 70 26l92 0q52 0 70-26z m-54-112l84 0q-92 110-104 126-14 16-32 16l-102 0q-22 0-32-16l-106-126 84 0 64 66 82 0z" horiz-adv-x="760" />
|
||||
<glyph glyph-name="up-big" unicode="" d="M899 308q0-28-21-50l-41-42q-22-21-51-21-30 0-50 21l-165 164v-393q0-29-20-47t-51-19h-71q-30 0-51 19t-21 47v393l-164-164q-20-21-50-21t-50 21l-42 42q-21 21-21 50 0 30 21 51l363 363q20 21 50 21 30 0 51-21l363-363q21-22 21-51z" horiz-adv-x="928.6" />
|
||||
|
||||
<glyph glyph-name="plus-circled" unicode="" d="M420 770q174 0 297-123t123-297-123-297-297-123-297 123-123 297 123 297 297 123z m52-470l200 0 0 102-200 0 0 202-102 0 0-202-202 0 0-102 202 0 0-202 102 0 0 202z" horiz-adv-x="840" />
|
||||
<glyph glyph-name="clone" unicode="" d="M929-61v607q0 8-6 13t-12 5h-607q-8 0-13-5t-5-13v-607q0-7 5-12t13-6h607q7 0 12 6t6 12z m71 607v-607q0-37-26-63t-63-26h-607q-37 0-63 26t-27 63v607q0 37 27 64t63 26h607q37 0 63-26t26-64z m-214 215v-90h-72v90q0 7-5 12t-13 6h-607q-7 0-12-6t-6-12v-607q0-8 6-13t12-5h90v-72h-90q-36 0-63 27t-26 63v607q0 37 26 63t63 26h607q37 0 64-26t26-63z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="minus-circled" unicode="" d="M420 770q174 0 297-123t123-297-123-297-297-123-297 123-123 297 123 297 297 123z m252-368l-504 0 0-102 504 0 0 102z" horiz-adv-x="840" />
|
||||
|
||||
<glyph glyph-name="login" unicode="" d="M661 350q0-14-11-25l-303-304q-11-10-26-10t-25 10-10 25v161h-250q-15 0-25 11t-11 25v214q0 15 11 25t25 11h250v161q0 14 10 25t25 10 26-10l303-304q11-10 11-25z m196 196v-392q0-67-47-114t-114-47h-178q-7 0-13 5t-5 13q0 2-1 11t0 15 2 13 5 11 12 3h178q37 0 64 27t26 63v392q0 37-26 64t-64 26h-174t-6 0-6 2-5 3-4 5-1 8q0 2-1 11t0 15 2 13 5 11 12 3h178q67 0 114-47t47-114z" horiz-adv-x="857.1" />
|
||||
<glyph glyph-name="check" unicode="" d="M933 534q0-22-16-38l-404-404-76-76q-16-15-38-15t-38 15l-76 76-202 202q-15 16-15 38t15 38l76 76q16 16 38 16t38-16l164-165 366 367q16 16 38 16t38-16l76-76q16-15 16-38z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="down-big" unicode="" d="M899 386q0-30-21-50l-363-364q-22-21-51-21-29 0-50 21l-363 364q-21 20-21 50 0 29 21 51l41 41q22 21 51 21 29 0 50-21l164-164v393q0 29 21 50t51 22h71q29 0 50-22t21-50v-393l165 164q20 21 50 21 29 0 51-21l41-41q21-22 21-51z" horiz-adv-x="928.6" />
|
||||
<glyph glyph-name="github" unicode="" d="M357 171q0-22-7-45t-24-43-40-19-41 19-24 43-7 45 7 46 24 43 41 19 40-19 24-43 7-46z m357 0q0-22-7-45t-24-43-40-19-41 19-24 43-7 45 7 46 24 43 41 19 40-19 24-43 7-46z m90 0q0 67-39 114t-104 47q-23 0-109-12-40-6-88-6t-87 6q-85 12-109 12-66 0-104-47t-39-114q0-49 18-85t45-58 68-33 78-17 83-4h94q46 0 83 4t78 17 69 33 45 58 18 85z m125 99q0-116-34-185-22-43-59-74t-79-48-95-27-96-12-93-3q-43 0-79 2t-82 7-85 17-77 29-67 45-48 64q-35 69-35 185 0 132 76 221-15 45-15 95 0 64 28 121 61 0 106-22t106-69q82 20 172 20 83 0 157-18 58 46 104 67t105 22q29-57 29-121 0-49-15-94 76-89 76-222z" horiz-adv-x="928.6" />
|
||||
|
||||
<glyph glyph-name="up-big" unicode="" d="M899 308q0-28-21-50l-41-42q-22-21-51-21-30 0-50 21l-165 164v-393q0-29-20-47t-51-19h-71q-30 0-51 19t-21 47v393l-164-164q-20-21-50-21t-50 21l-42 42q-21 21-21 50 0 30 21 51l363 363q20 21 50 21 30 0 51-21l363-363q21-22 21-51z" horiz-adv-x="928.6" />
|
||||
<glyph glyph-name="login" unicode="" d="M661 350q0-14-11-25l-303-304q-11-10-26-10t-25 10-10 25v161h-250q-15 0-25 11t-11 25v214q0 15 11 25t25 11h250v161q0 14 10 25t25 10 26-10l303-304q11-10 11-25z m196 196v-392q0-67-47-114t-114-47h-178q-7 0-13 5t-5 13q0 2-1 11t0 15 2 13 5 11 12 3h178q37 0 64 27t26 63v392q0 37-26 64t-64 26h-174t-6 0-6 2-5 3-4 5-1 8q0 2-1 11t0 15 2 13 5 11 12 3h178q67 0 114-47t47-114z" horiz-adv-x="857.1" />
|
||||
|
||||
<glyph glyph-name="lock" unicode="" d="M179 421h285v108q0 59-42 101t-101 41-101-41-41-101v-108z m464-53v-322q0-22-16-37t-38-16h-535q-23 0-38 16t-16 37v322q0 22 16 38t38 15h17v108q0 102 74 176t176 74 177-74 73-176v-108h18q23 0 38-15t16-38z" horiz-adv-x="642.9" />
|
||||
|
||||
<glyph glyph-name="mimi" unicode="" d="M909 286c0-241-203-436-454-436s-455 195-455 436 204 564 455 564 454-324 454-564z m-454 396c-141 0-255-114-255-254s114-255 255-255 254 114 254 255-114 254-254 254z m91-254c0-51-41-91-91-91s-91 40-91 91 40 90 91 90 91-40 91-90z" horiz-adv-x="909" />
|
||||
|
||||
<glyph glyph-name="spin" unicode="" d="M46 144l0 0c0 0-1 0-1 0-8 18-15 37-21 55-6 19-11 38-15 58-19 99-8 203 35 298 3 6 10 8 15 5 1 0 2 0 2-1l0 0 80-59c5-3 6-9 4-14-5-12-9-25-12-37-4-13-7-26-9-40-11-67-3-137 23-201 2-5 0-10-4-13l0 0-80-56c-5-4-12-2-16 3-1 0-1 1-1 2l0 0z m120 574l0 0c0 1 0 1 0 1 15 13 30 25 46 37 16 11 33 22 51 31 89 50 192 72 297 60 6-1 10-6 10-13 0-1-1-1-1-2l0 0-31-94c-2-5-8-8-13-7-13 0-27 0-40 0-14-1-27-2-40-4-68-11-133-40-186-84-4-3-10-3-14 0l0 0-79 58c-5 3-6 11-2 16 0 0 1 1 2 1l0 0z m588 65l0 0c0 0 1 0 1 0 17-10 34-21 50-32 16-12 31-25 46-38 74-69 127-160 148-262 2-6-2-12-9-13-1 0-1 0-2 0l0 0-100 1c-5 0-10 4-11 9-3 13-8 26-12 38-5 12-10 25-17 36-31 61-78 113-137 150-5 3-6 8-5 13l0 0 31 92c2 6 9 9 15 7 1 0 2-1 2-1l0 0z m244-535l0 0c0 0 0 0 0 0-4-20-9-39-15-57-7-19-14-37-22-55-44-92-114-170-205-221-6-3-13-1-16 4 0 1-1 2-1 2l0 0-30 94c-2 6 1 12 6 14 11 7 22 15 32 23 11 9 21 18 30 27 49 48 84 109 101 176 2 5 6 8 11 8l0 0 98-1c6 0 11-5 11-11 0-1 0-2 0-3l0 0z m-438-395l0 0c0 0 0 0 0 0-20-2-40-3-60-3-20 0-40 1-59 4-102 12-198 54-276 125-5 4-5 11 0 16 0 0 1 1 1 1l0 0 81 58c5 3 12 2 16-2 10-8 20-16 32-23 11-7 22-14 34-20 62-31 131-45 200-41 6 0 10-3 12-8l0 0 29-92c2-6-1-12-7-14-1-1-2-1-3-1l0 0z" horiz-adv-x="1000" />
|
||||
|
||||
@ -84,14 +94,14 @@
|
||||
|
||||
<glyph glyph-name="sort" unicode="" d="M571 243q0-15-10-25l-250-250q-11-11-25-11t-25 11l-250 250q-11 10-11 25t11 25 25 11h500q14 0 25-11t10-25z m0 214q0-14-10-25t-25-11h-500q-15 0-25 11t-11 25 11 25l250 250q10 11 25 11t25-11l250-250q10-10 10-25z" horiz-adv-x="571.4" />
|
||||
|
||||
<glyph glyph-name="mail-alt" unicode="" d="M1000 454v-443q0-37-26-63t-63-27h-822q-36 0-63 27t-26 63v443q25-27 56-49 202-137 278-192 32-24 51-37t53-27 61-13h2q28 0 61 13t53 27 51 37q95 68 278 192 32 22 56 49z m0 164q0-44-27-84t-68-69q-210-146-262-181-5-4-23-17t-30-22-29-18-32-15-28-5h-2q-12 0-27 5t-32 15-30 18-30 22-23 17q-51 35-147 101t-114 80q-35 23-65 64t-31 77q0 43 23 72t66 29h822q36 0 63-26t26-63z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="linkedin" unicode="" d="M195 501v-553h-184v553h184z m12 171q0-41-29-68t-75-27h-1q-46 0-74 27t-28 68q0 41 29 68t75 27 74-27 29-68z m650-407v-317h-183v296q0 59-23 92t-71 33q-35 0-58-19t-36-48q-6-17-6-45v-309h-184q1 223 1 361t0 165l-1 27h184v-80h-1q11 18 23 31t31 29 49 24 64 9q95 0 153-63t58-186z" horiz-adv-x="857.1" />
|
||||
|
||||
<glyph glyph-name="download-cloud" unicode="" d="M714 332q0 8-5 13t-13 5h-125v196q0 8-5 13t-12 5h-108q-7 0-12-5t-5-13v-196h-125q-8 0-13-5t-5-13q0-8 5-13l196-196q5-5 13-5t13 5l196 196q5 6 5 13z m357-125q0-89-62-151t-152-63h-607q-103 0-177 73t-73 177q0 72 39 134t105 92q-1 17-1 24 0 118 84 202t202 84q87 0 159-49t105-129q40 35 93 35 59 0 101-42t42-101q0-43-23-77 72-17 119-76t46-133z" horiz-adv-x="1071.4" />
|
||||
|
||||
<glyph glyph-name="upload-cloud" unicode="" d="M714 368q0 8-5 13l-196 196q-5 5-13 5t-13-5l-196-196q-5-6-5-13 0-8 5-13t13-5h125v-196q0-8 5-13t12-5h108q7 0 12 5t5 13v196h125q8 0 13 5t5 13z m357-161q0-89-62-151t-152-63h-607q-103 0-177 73t-73 177q0 72 39 134t105 92q-1 17-1 24 0 118 84 202t202 84q87 0 159-49t105-129q40 35 93 35 59 0 101-42t42-101q0-43-23-77 72-17 119-76t46-133z" horiz-adv-x="1071.4" />
|
||||
|
||||
<glyph glyph-name="github" unicode="" d="M357 171q0-22-7-45t-24-43-40-19-41 19-24 43-7 45 7 46 24 43 41 19 40-19 24-43 7-46z m357 0q0-22-7-45t-24-43-40-19-41 19-24 43-7 45 7 46 24 43 41 19 40-19 24-43 7-46z m90 0q0 67-39 114t-104 47q-23 0-109-12-40-6-88-6t-87 6q-85 12-109 12-66 0-104-47t-39-114q0-49 18-85t45-58 68-33 78-17 83-4h94q46 0 83 4t78 17 69 33 45 58 18 85z m125 99q0-116-34-185-22-43-59-74t-79-48-95-27-96-12-93-3q-43 0-79 2t-82 7-85 17-77 29-67 45-48 64q-35 69-35 185 0 132 76 221-15 45-15 95 0 64 28 121 61 0 106-22t106-69q82 20 172 20 83 0 157-18 58 46 104 67t105 22q29-57 29-121 0-49-15-94 76-89 76-222z" horiz-adv-x="928.6" />
|
||||
|
||||
<glyph glyph-name="code" unicode="" d="M344 69l-28-28q-5-5-12-5t-13 5l-260 261q-6 5-6 12t6 13l260 260q5 6 13 6t12-6l28-28q6-5 6-13t-6-12l-219-220 219-219q6-6 6-13t-6-13z m330 596l-208-721q-2-7-9-11t-13-1l-34 9q-8 3-11 9t-2 14l209 720q2 8 8 11t13 2l35-10q7-2 11-9t1-13z m367-363l-260-261q-6-5-13-5t-13 5l-28 28q-5 6-5 13t5 13l219 219-219 220q-5 5-5 12t5 13l28 28q6 6 13 6t13-6l260-260q5-5 5-13t-5-12z" horiz-adv-x="1071.4" />
|
||||
|
||||
<glyph glyph-name="youtube" unicode="" d="M542 156v-118q0-37-22-37-13 0-25 12v168q12 12 25 12 22 0 22-37z m189-1v-25h-51v25q0 38 25 38t26-38z m-540 122h60v52h-174v-52h59v-318h55v318z m161-318h50v276h-50v-211q-17-23-32-23-10 0-11 11-1 2-1 20v203h-50v-218q0-28 5-41 7-21 32-21 27 0 57 34v-30z m240 83v110q0 41-5 55-10 31-40 31-28 0-52-30v121h-50v-370h50v27q25-31 52-31 30 0 40 31 5 15 5 56z m188 6v7h-51q0-29-1-34-4-20-22-20-26 0-26 38v49h100v57q0 44-15 65-22 28-59 28-38 0-60-28-15-21-15-65v-96q0-44 16-65 22-29 60-29 40 0 60 30 10 15 12 30 1 5 1 33z m-339 509v117q0 39-24 39t-24-39v-117q0-39 24-39t24 39z m401-419q0-131-14-195-8-33-33-56t-57-25q-102-12-309-12t-310 12q-32 3-57 25t-32 56q-15 62-15 195 0 131 15 195 7 33 32 56t57 26q103 11 310 11t309-11q33-4 58-26t32-56q14-62 14-195z m-557 712h57l-67-223v-151h-56v151q-8 42-34 119-21 57-37 104h60l39-147z m207-186v-97q0-46-16-66-21-29-59-29-37 0-59 29-15 21-15 66v97q0 45 15 66 22 28 59 28 38 0 59-28 16-21 16-66z m187 91v-279h-51v31q-30-35-58-35-25 0-33 21-4 13-4 42v220h51v-205q0-19 0-20 2-12 12-12 15 0 32 24v213h51z" horiz-adv-x="857.1" />
|
||||
@ -101,8 +111,6 @@
|
||||
<glyph glyph-name="brush" unicode="" d="M901 850q39 0 69-26t29-65q0-35-25-84-185-351-260-420-54-51-121-51-71 0-121 52t-51 123q0 71 52 118l356 323q33 30 72 30z m-507-577q22-42 59-73t84-42l1-40q2-118-72-193t-195-75q-68 0-121 26t-85 71-49 102-16 123q4-3 23-17t35-25 32-20 26-9q23 0 31 20 14 37 32 63t39 42 49 27 57 14 70 6z" horiz-adv-x="1000" />
|
||||
|
||||
<glyph glyph-name="pinterest" unicode="" d="M0 517q0 60 21 113t58 93 85 69 103 44 113 14q88 0 164-37t123-108 47-160q0-54-10-105t-34-99-56-83-80-58-106-21q-38 0-75 18t-54 49q-5-22-15-63t-14-53-11-40-15-39-17-35-26-44-35-48l-7-3-5 6q-9 88-9 105 0 51 12 115t37 161 29 113q-18 36-18 94 0 47 29 87t74 41q34 0 53-23t19-57q0-37-24-106t-25-105q0-35 25-58t61-23q31 0 57 14t44 38 31 53 21 61 11 62 4 56q0 96-61 150t-160 54q-111 0-186-72t-75-183q0-25 7-48t15-36 15-26 7-17q0-15-8-40t-21-25q-1 0-9 1-29 9-51 31t-34 53-18 60-6 60z" horiz-adv-x="714.3" />
|
||||
|
||||
<glyph glyph-name="clone" unicode="" d="M929-61v607q0 8-6 13t-12 5h-607q-8 0-13-5t-5-13v-607q0-7 5-12t13-6h607q7 0 12 6t6 12z m71 607v-607q0-37-26-63t-63-26h-607q-37 0-63 26t-27 63v607q0 37 27 64t63 26h607q37 0 63-26t26-64z m-214 215v-90h-72v90q0 7-5 12t-13 6h-607q-7 0-12-6t-6-12v-607q0-8 6-13t12-5h90v-72h-90q-36 0-63 27t-26 63v607q0 37 26 63t63 26h607q37 0 64-26t26-63z" horiz-adv-x="1000" />
|
||||
</font>
|
||||
</defs>
|
||||
</svg>
|
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 23 KiB |
BIN
core/vendor/zwiico/font/zwiico.ttf
vendored
BIN
core/vendor/zwiico/font/zwiico.woff
vendored
BIN
core/vendor/zwiico/font/zwiico.woff2
vendored
@ -14,10 +14,16 @@
|
||||
|
||||
class blog extends common {
|
||||
|
||||
const EDIT_OWNER = 'owner';
|
||||
const EDIT_GROUP = 'group';
|
||||
const EDIT_ALL = 'all';
|
||||
|
||||
public static $actions = [
|
||||
'add' => self::GROUP_MODERATOR,
|
||||
'comment' => self::GROUP_MODERATOR,
|
||||
'commentApprove' => self::GROUP_MODERATOR,
|
||||
'commentDelete' => self::GROUP_MODERATOR,
|
||||
'commentDeleteAll' => self::GROUP_MODERATOR,
|
||||
'config' => self::GROUP_MODERATOR,
|
||||
'delete' => self::GROUP_MODERATOR,
|
||||
'edit' => self::GROUP_MODERATOR,
|
||||
@ -27,8 +33,21 @@ class blog extends common {
|
||||
|
||||
public static $articles = [];
|
||||
|
||||
// Signature de l'article
|
||||
public static $articleSignature = '';
|
||||
|
||||
// Signature du commentaire
|
||||
public static $editCommentSignature = '';
|
||||
|
||||
public static $comments = [];
|
||||
|
||||
public static $nbCommentsApproved = 0;
|
||||
|
||||
public static $commentsDelete;
|
||||
|
||||
// Signatures des commentaires déjà saisis
|
||||
public static $commentsSignature = [];
|
||||
|
||||
public static $pages;
|
||||
|
||||
public static $states = [
|
||||
@ -49,12 +68,28 @@ class blog extends common {
|
||||
'right' => 'À droite ',
|
||||
];
|
||||
|
||||
//Paramètre longueur maximale des commentaires en nb de caractères
|
||||
public static $commentLength = [
|
||||
'500' => '500',
|
||||
'1000' => '1000',
|
||||
'2000' => '2000',
|
||||
'5000' => '5000',
|
||||
'10000' => '10000'
|
||||
];
|
||||
|
||||
// Permissions d'un article
|
||||
public static $articleConsent = [
|
||||
self::EDIT_ALL => 'Tous les groupes',
|
||||
self::EDIT_GROUP => 'Groupe du propriétaire',
|
||||
self::EDIT_OWNER => 'Propriétaire'
|
||||
];
|
||||
|
||||
|
||||
public static $users = [];
|
||||
|
||||
const BLOG_VERSION = '2.13';
|
||||
const BLOG_VERSION = '4.2';
|
||||
|
||||
/**
|
||||
/**
|
||||
* Flux RSS
|
||||
*/
|
||||
public function rss() {
|
||||
@ -68,11 +103,11 @@ class blog extends common {
|
||||
$feeds = new \FeedWriter\RSS2();
|
||||
|
||||
// En-tête
|
||||
$feeds->setTitle($this->getData (['page', $this->getUrl(0), 'posts','title']));
|
||||
$feeds->setTitle($this->getData (['page', $this->getUrl(0), 'title']));
|
||||
$feeds->setLink(helper::baseUrl() . $this->getUrl(0));
|
||||
$feeds->setDescription(html_entity_decode(strip_tags($this->getData (['page', $this->getUrl(0), 'metaDescription']))));
|
||||
$feeds->setDescription($this->getData (['page', $this->getUrl(0), 'metaDescription']));
|
||||
$feeds->setChannelElement('language', 'fr-FR');
|
||||
$feeds->setDate(time());
|
||||
$feeds->setDate(date('r',time()));
|
||||
$feeds->addGenerator();
|
||||
// Corps des articles
|
||||
$articleIdsPublishedOns = helper::arrayCollumn($this->getData(['module', $this->getUrl(0), 'posts']), 'publishedOn', 'SORT_DESC');
|
||||
@ -84,12 +119,25 @@ class blog extends common {
|
||||
$thumb = str_replace ($parts[(count($parts)-1)],'mini_' . $parts[(count($parts)-1)], $this->getData(['module', $this->getUrl(0), 'posts', $articleId, 'picture']));
|
||||
// Créer les articles du flux
|
||||
$newsArticle = $feeds->createNewItem();
|
||||
// Signature de l'article
|
||||
$author = $this->signature($this->getData(['module', $this->getUrl(0), 'posts', $articleId, 'userId']));
|
||||
$newsArticle->addElementArray([
|
||||
'title' => strip_tags($this->getData(['module', $this->getUrl(0), 'posts', $articleId, 'title']) ),
|
||||
'link' => helper::baseUrl() .$this->getUrl(0) . '/' . $articleId,
|
||||
'description' => html_entity_decode(strip_tags($this->getData(['module', $this->getUrl(0), 'posts', $articleId, 'content']))),
|
||||
'addEnclosure' => helper::baseUrl() . self::FILE_DIR . $thumb
|
||||
'title' => $this->getData(['module', $this->getUrl(0), 'posts', $articleId, 'title']),
|
||||
'link' => helper::baseUrl() .$this->getUrl(0) . '/' . $articleId,
|
||||
'description' => '<img src="' . helper::baseUrl() . self::FILE_DIR . $thumb
|
||||
. '" alt="' . $this->getData(['module', $this->getUrl(0), 'posts', $articleId, 'title'])
|
||||
. '" title="' . $this->getData(['module', $this->getUrl(0), 'posts', $articleId, 'title'])
|
||||
. '" />' .
|
||||
$this->getData(['module', $this->getUrl(0), 'posts', $articleId, 'content']),
|
||||
]);
|
||||
$newsArticle->setAuthor($author,'no@mail.com');
|
||||
$newsArticle->setId(helper::baseUrl() .$this->getUrl(0) . '/' . $articleId);
|
||||
$newsArticle->setDate(date('r', $this->getData(['module', $this->getUrl(0), 'posts', $articleId, 'publishedOn'])));
|
||||
$imageData = getimagesize(helper::baseUrl(false) . self::FILE_DIR . 'thumb/' . $thumb);
|
||||
$newsArticle->addEnclosure( helper::baseUrl(false) . self::FILE_DIR . 'thumb/' . $thumb,
|
||||
$imageData[0] * $imageData[1],
|
||||
$imageData['mime']
|
||||
);
|
||||
$feeds->addItem($newsArticle);
|
||||
}
|
||||
}
|
||||
@ -108,26 +156,40 @@ class blog extends common {
|
||||
public function add() {
|
||||
// Soumission du formulaire
|
||||
if($this->isPost()) {
|
||||
// Modification de l'userId
|
||||
if($this->getUser('group') === self::GROUP_ADMIN){
|
||||
$newuserid = $this->getInput('blogAddUserId', helper::FILTER_STRING_SHORT, true);
|
||||
}
|
||||
else{
|
||||
$newuserid = $this->getUser('id');
|
||||
}
|
||||
// Incrémente l'id de l'article
|
||||
$articleId = helper::increment($this->getInput('blogAddTitle', helper::FILTER_ID), $this->getData(['page']));
|
||||
$articleId = helper::increment($articleId, (array) $this->getData(['module', $this->getUrl(0)]));
|
||||
$articleId = helper::increment($articleId, array_keys(self::$actions));
|
||||
// Crée l'article
|
||||
$this->setData(['module', $this->getUrl(0), 'posts', $articleId, [
|
||||
'closeComment' => $this->getInput('blogAddCloseComment', helper::FILTER_BOOLEAN),
|
||||
'mailNotification' => $this->getInput('blogAddMailNotification', helper::FILTER_BOOLEAN),
|
||||
'groupNotification' => $this->getInput('blogAddGroupNotification', helper::FILTER_INT),
|
||||
'comment' => [],
|
||||
'content' => $this->getInput('blogAddContent', null),
|
||||
'picture' => $this->getInput('blogAddPicture', helper::FILTER_STRING_SHORT, true),
|
||||
'hidePicture' => $this->getInput('blogAddHidePicture', helper::FILTER_BOOLEAN),
|
||||
'pictureSize' => $this->getInput('blogAddPictureSize', helper::FILTER_STRING_SHORT),
|
||||
'picturePosition' => $this->getInput('blogAddPicturePosition', helper::FILTER_STRING_SHORT),
|
||||
'publishedOn' => $this->getInput('blogAddPublishedOn', helper::FILTER_DATETIME, true),
|
||||
'state' => $this->getInput('blogAddState', helper::FILTER_BOOLEAN),
|
||||
'title' => $this->getInput('blogAddTitle', helper::FILTER_STRING_SHORT, true),
|
||||
'userId' => $this->getInput('blogAddUserId', helper::FILTER_ID, true)
|
||||
]]);
|
||||
$this->setData(['module',
|
||||
$this->getUrl(0),
|
||||
'posts',
|
||||
$articleId, [
|
||||
'comment' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment']),
|
||||
'content' => $this->getInput('blogAddContent', null),
|
||||
'picture' => $this->getInput('blogAddPicture', helper::FILTER_STRING_SHORT, true),
|
||||
'hidePicture' => $this->getInput('blogAddHidePicture', helper::FILTER_BOOLEAN),
|
||||
'pictureSize' => $this->getInput('blogAddPictureSize', helper::FILTER_STRING_SHORT),
|
||||
'picturePosition' => $this->getInput('blogAddPicturePosition', helper::FILTER_STRING_SHORT),
|
||||
'publishedOn' => $this->getInput('blogAddPublishedOn', helper::FILTER_DATETIME, true),
|
||||
'state' => $this->getInput('blogAddState', helper::FILTER_BOOLEAN),
|
||||
'title' => $this->getInput('blogAddTitle', helper::FILTER_STRING_SHORT, true),
|
||||
'userId' => $newuserid,
|
||||
'editConsent' => $this->getInput('blogAddConsent') === self::EDIT_GROUP ? $this->getUser('group') : $this->getInput('blogAddConsent'),
|
||||
'commentMaxlength' => $this->getInput('blogAddCommentMaxlength'),
|
||||
'commentApproved' => $this->getInput('blogAddCommentApproved', helper::FILTER_BOOLEAN),
|
||||
'commentClose' => $this->getInput('blogAddCommentClose', helper::FILTER_BOOLEAN),
|
||||
'commentNotification' => $this->getInput('blogAddCommentNotification', helper::FILTER_BOOLEAN),
|
||||
'commentGroupNotification' => $this->getInput('blogAddCommentGroupNotification', helper::FILTER_INT)
|
||||
]
|
||||
]);
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl(0) . '/config',
|
||||
@ -157,14 +219,13 @@ class blog extends common {
|
||||
* Liste des commentaires
|
||||
*/
|
||||
public function comment() {
|
||||
// Liste les commentaires
|
||||
$comments = [];
|
||||
foreach((array) $this->getData(['module', $this->getUrl(0), 'posts']) as $articleId => $article) {
|
||||
foreach($article['comment'] as &$comment) {
|
||||
$comment['articleId'] = $articleId;
|
||||
}
|
||||
$comments += $article['comment'];
|
||||
}
|
||||
$comments = $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2),'comment']);
|
||||
self::$commentsDelete = template::button('blogCommentDeleteAll', [
|
||||
'class' => 'blogCommentDeleteAll buttonRed',
|
||||
'href' => helper::baseUrl() . $this->getUrl(0) . '/commentDeleteAll/' . $this->getUrl(2).'/' . $_SESSION['csrf'] ,
|
||||
'ico' => 'cancel',
|
||||
'value' => 'Tout effacer'
|
||||
]);
|
||||
// Ids des commentaires par ordre de création
|
||||
$commentIds = array_keys(helper::arrayCollumn($comments, 'createdOn', 'SORT_DESC'));
|
||||
// Pagination
|
||||
@ -175,22 +236,34 @@ class blog extends common {
|
||||
for($i = $pagination['first']; $i < $pagination['last']; $i++) {
|
||||
// Met en forme le tableau
|
||||
$comment = $comments[$commentIds[$i]];
|
||||
// Bouton d'approbation
|
||||
$buttonApproval = '';
|
||||
// Compatibilité avec les commentaires des versions précédentes, les valider
|
||||
$comment['approval'] = array_key_exists('approval', $comment) === false ? true : $comment['approval'] ;
|
||||
if ( $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2),'commentApproved']) === true) {
|
||||
$buttonApproval = template::button('blogCommentApproved' . $commentIds[$i], [
|
||||
'class' => $comment['approval'] === true ? 'blogCommentRejected buttonGreen' : 'blogCommentApproved buttonRed' ,
|
||||
'href' => helper::baseUrl() . $this->getUrl(0) . '/commentApprove/' . $this->getUrl(2) . '/' . $commentIds[$i] . '/' . $_SESSION['csrf'] ,
|
||||
'value' => $comment['approval'] === true ? 'A' : 'R'
|
||||
]);
|
||||
}
|
||||
self::$comments[] = [
|
||||
mb_detect_encoding(strftime('%d %B %Y - %H:%M', $comment['createdOn']), 'UTF-8', true)
|
||||
? strftime('%d %B %Y - %H:%M', $comment['createdOn'])
|
||||
: utf8_encode(strftime('%d %B %Y - %H:%M', $comment['createdOn'])),
|
||||
$comment['content'],
|
||||
$comment['userId'] ? $this->getData(['user', $comment['userId'], 'firstname']) . ' ' . $this->getData(['user', $comment['userId'], 'lastname']) : $comment['author'],
|
||||
$buttonApproval,
|
||||
template::button('blogCommentDelete' . $commentIds[$i], [
|
||||
'class' => 'blogCommentDelete buttonRed',
|
||||
'href' => helper::baseUrl() . $this->getUrl(0) . '/comment-delete/' . $comment['articleId'] . '/' . $commentIds[$i] . '/' . $_SESSION['csrf'] ,
|
||||
'href' => helper::baseUrl() . $this->getUrl(0) . '/commentDelete/' . $this->getUrl(2) . '/' . $commentIds[$i] . '/' . $_SESSION['csrf'] ,
|
||||
'value' => template::ico('cancel')
|
||||
])
|
||||
];
|
||||
}
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'title' => 'Gestion des commentaires',
|
||||
'title' => 'Gestion des commentaires : '. $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'title']),
|
||||
'view' => 'comment'
|
||||
]);
|
||||
}
|
||||
@ -219,13 +292,76 @@ class blog extends common {
|
||||
$this->deleteData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment', $this->getUrl(3)]);
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl(0) . '/comment',
|
||||
'redirect' => helper::baseUrl() . $this->getUrl(0) . '/comment/'.$this->getUrl(2),
|
||||
'notification' => 'Commentaire supprimé',
|
||||
'state' => true
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Suppression de tous les commentaires de l'article $this->getUrl(2)
|
||||
*/
|
||||
public function commentDeleteAll() {
|
||||
// Jeton incorrect
|
||||
if ($this->getUrl(3) !== $_SESSION['csrf']) {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl(0) . '/config',
|
||||
'notification' => 'Action non autorisée'
|
||||
]);
|
||||
}
|
||||
// Suppression
|
||||
else {
|
||||
$this->setData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment',[] ]);
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl(0) . '/comment',
|
||||
'notification' => 'Commentaires supprimés',
|
||||
'state' => true
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Approbation oou désapprobation de commentaire
|
||||
*/
|
||||
public function commentApprove() {
|
||||
// Le commentaire n'existe pas
|
||||
if($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment', $this->getUrl(3)]) === null) {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'access' => false
|
||||
]);
|
||||
}
|
||||
// Jeton incorrect
|
||||
elseif ($this->getUrl(4) !== $_SESSION['csrf']) {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl(0) . '/config',
|
||||
'notification' => 'Action non autorisée'
|
||||
]);
|
||||
}
|
||||
// Inversion du statut
|
||||
else {
|
||||
$approved = !$this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment', $this->getUrl(3), 'approval']) ;
|
||||
$this->setData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment', $this->getUrl(3), [
|
||||
'author' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment', $this->getUrl(3), 'author']),
|
||||
'content' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment', $this->getUrl(3), 'content']),
|
||||
'createdOn' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment', $this->getUrl(3), 'createdOn']),
|
||||
'userId' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment', $this->getUrl(3), 'userId']),
|
||||
'approval' => $approved
|
||||
]]);
|
||||
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl(0) . '/comment/'.$this->getUrl(2),
|
||||
'notification' => $approved ? 'Commentaire approuvé' : 'Commentaire rejeté',
|
||||
'state' => $approved
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Configuration
|
||||
*/
|
||||
@ -244,25 +380,66 @@ class blog extends common {
|
||||
]);
|
||||
} else {
|
||||
// Ids des articles par ordre de publication
|
||||
$articleIds = array_keys(helper::arrayCollumn($this->getData(['module', $this->getUrl(0),'posts']), 'publishedOn', 'SORT_DESC'));
|
||||
// Supprimer le bloc config
|
||||
$articleIds = array_keys(helper::arrayCollumn($this->getData(['module', $this->getUrl(0), 'posts']), 'publishedOn', 'SORT_DESC'));
|
||||
// Gestion des droits d'accès
|
||||
$filterData=[];
|
||||
foreach ($articleIds as $key => $value) {
|
||||
if (
|
||||
( // Propriétaire
|
||||
$this->getData(['module', $this->getUrl(0), 'posts', $value,'editConsent']) === self::EDIT_OWNER
|
||||
AND ( $this->getData(['module', $this->getUrl(0), 'posts', $value,'userId']) === $this->getUser('id')
|
||||
OR $this->getUser('group') === self::GROUP_ADMIN )
|
||||
)
|
||||
|
||||
OR (
|
||||
// Groupe
|
||||
$this->getData(['module', $this->getUrl(0), 'posts', $value,'editConsent']) !== self::EDIT_OWNER
|
||||
AND $this->getUser('group') >= $this->getData(['module',$this->getUrl(0), 'posts', $value,'editConsent'])
|
||||
)
|
||||
OR (
|
||||
// Tout le monde
|
||||
$this->getData(['module', $this->getUrl(0), 'posts', $value,'editConsent']) === self::EDIT_ALL
|
||||
)
|
||||
) {
|
||||
$filterData[] = $value;
|
||||
}
|
||||
}
|
||||
$articleIds = $filterData;
|
||||
// Pagination
|
||||
$pagination = helper::pagination($articleIds, $this->getUrl(),$this->getData(['config','itemsperPage']));
|
||||
// Liste des pages
|
||||
self::$pages = $pagination['pages'];
|
||||
// Articles en fonction de la pagination
|
||||
for($i = $pagination['first']; $i < $pagination['last']; $i++) {
|
||||
// Nombre de commentaires à approuver et approuvés
|
||||
$approvals = helper::arrayCollumn($this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i], 'comment' ]),'approval', 'SORT_DESC');
|
||||
if ( is_array($approvals) ) {
|
||||
$a = array_values($approvals);
|
||||
$toApprove = count(array_keys($a,false));
|
||||
$approved = count(array_keys($a,true));
|
||||
} else {
|
||||
$toApprove = 0;
|
||||
$approved = count($this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i],'comment']));
|
||||
}
|
||||
// Met en forme le tableau
|
||||
$date = mb_detect_encoding(strftime('%d %B %Y', $this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i], 'publishedOn'])), 'UTF-8', true)
|
||||
$date = mb_detect_encoding(strftime('%d %B %Y', $this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i], 'publishedOn'])), 'UTF-8', true)
|
||||
? strftime('%d %B %Y', $this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i], 'publishedOn']))
|
||||
: utf8_encode(strftime('%d %B %Y', $this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i], 'publishedOn'])));
|
||||
$heure = mb_detect_encoding(strftime('%H:%M', $this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i], 'publishedOn'])), 'UTF-8', true)
|
||||
? strftime('%H:%M', $this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i], 'publishedOn']))
|
||||
: utf8_encode(strftime('%H:%M', $this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i], 'publishedOn'])));
|
||||
self::$articles[] = [
|
||||
$this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i], 'title']),
|
||||
'<a href="' . helper::baseurl() . $this->getUrl(0) . '/' . $articleIds[$i] . '" target="_blank" >' .
|
||||
$this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i], 'title']) .
|
||||
'</a>',
|
||||
$date .' à '. $heure,
|
||||
self::$states[$this->getData(['module', $this->getUrl(0), 'posts', $articleIds[$i], 'state'])],
|
||||
// Bouton pour afficher les commentaires de l'article
|
||||
template::button('blogConfigComment' . $articleIds[$i], [
|
||||
'class' => ($toApprove || $approved ) > 0 ? 'buttonBlue' : 'buttonGrey' ,
|
||||
'href' => ($toApprove || $approved ) > 0 ? helper::baseUrl() . $this->getUrl(0) . '/comment/' . $articleIds[$i] : '',
|
||||
'value' => $toApprove > 0 ? $toApprove . '/' . $approved : $approved
|
||||
]),
|
||||
template::button('blogConfigEdit' . $articleIds[$i], [
|
||||
'href' => helper::baseUrl() . $this->getUrl(0) . '/edit/' . $articleIds[$i] . '/' . $_SESSION['csrf'],
|
||||
'value' => template::ico('pencil')
|
||||
@ -335,28 +512,41 @@ class blog extends common {
|
||||
else {
|
||||
// Soumission du formulaire
|
||||
if($this->isPost()) {
|
||||
if($this->getUser('group') === self::GROUP_ADMIN){
|
||||
$newuserid = $this->getInput('blogEditUserId', helper::FILTER_STRING_SHORT, true);
|
||||
}
|
||||
else{
|
||||
$newuserid = $this->getUser('id');
|
||||
}
|
||||
$articleId = $this->getInput('blogEditTitle', helper::FILTER_ID, true);
|
||||
// Incrémente le nouvel id de l'article
|
||||
if($articleId !== $this->getUrl(2)) {
|
||||
$articleId = helper::increment($articleId, $this->getData(['page']));
|
||||
$articleId = helper::increment($articleId, $this->getData(['module', $this->getUrl(0)]));
|
||||
$articleId = helper::increment($articleId, $this->getData(['module', $this->getUrl(0),'posts']));
|
||||
$articleId = helper::increment($articleId, array_keys(self::$actions));
|
||||
}
|
||||
$this->setData(['module', $this->getUrl(0), 'posts', $articleId, [
|
||||
'closeComment' => $this->getInput('blogEditCloseComment'),
|
||||
'mailNotification' => $this->getInput('blogEditMailNotification', helper::FILTER_BOOLEAN),
|
||||
'groupNotification' => $this->getInput('blogEditGroupNotification', helper::FILTER_INT),
|
||||
'comment' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment']),
|
||||
'content' => $this->getInput('blogEditContent', null),
|
||||
'picture' => $this->getInput('blogEditPicture', helper::FILTER_STRING_SHORT, true),
|
||||
'hidePicture' => $this->getInput('blogEditHidePicture', helper::FILTER_BOOLEAN),
|
||||
'pictureSize' => $this->getInput('blogEditPictureSize', helper::FILTER_STRING_SHORT),
|
||||
'picturePosition' => $this->getInput('blogEditPicturePosition', helper::FILTER_STRING_SHORT),
|
||||
'publishedOn' => $this->getInput('blogEditPublishedOn', helper::FILTER_DATETIME, true),
|
||||
'state' => $this->getInput('blogEditState', helper::FILTER_BOOLEAN),
|
||||
'title' => $this->getInput('blogEditTitle', helper::FILTER_STRING_SHORT, true),
|
||||
'userId' => $this->getInput('blogEditUserId', helper::FILTER_ID, true)
|
||||
]]);
|
||||
$this->setData(['module',
|
||||
$this->getUrl(0),
|
||||
'posts',
|
||||
$articleId, [
|
||||
'comment' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'comment']),
|
||||
'content' => $this->getInput('blogEditContent', null),
|
||||
'picture' => $this->getInput('blogEditPicture', helper::FILTER_STRING_SHORT, true),
|
||||
'hidePicture' => $this->getInput('blogEditHidePicture', helper::FILTER_BOOLEAN),
|
||||
'pictureSize' => $this->getInput('blogEditPictureSize', helper::FILTER_STRING_SHORT),
|
||||
'picturePosition' => $this->getInput('blogEditPicturePosition', helper::FILTER_STRING_SHORT),
|
||||
'publishedOn' => $this->getInput('blogEditPublishedOn', helper::FILTER_DATETIME, true),
|
||||
'state' => $this->getInput('blogEditState', helper::FILTER_BOOLEAN),
|
||||
'title' => $this->getInput('blogEditTitle', helper::FILTER_STRING_SHORT, true),
|
||||
'userId' => $newuserid,
|
||||
'editConsent' => $this->getInput('blogEditConsent') === self::EDIT_GROUP ? $this->getUser('group') : $this->getInput('blogEditConsent'),
|
||||
'commentMaxlength' => $this->getInput('blogEditCommentMaxlength'),
|
||||
'commentApproved' => $this->getInput('blogEditCommentApproved', helper::FILTER_BOOLEAN),
|
||||
'commentClose' => $this->getInput('blogEditCommentClose', helper::FILTER_BOOLEAN),
|
||||
'commentNotification' => $this->getInput('blogEditCommentNotification', helper::FILTER_BOOLEAN),
|
||||
'commentGroupNotification' => $this->getInput('blogEditCommentGroupNotification', helper::FILTER_INT)
|
||||
]
|
||||
]);
|
||||
// Supprime l'ancien article
|
||||
if($articleId !== $this->getUrl(2)) {
|
||||
$this->deleteData(['module', $this->getUrl(0), 'posts', $this->getUrl(2)]);
|
||||
@ -372,7 +562,11 @@ class blog extends common {
|
||||
self::$users = helper::arrayCollumn($this->getData(['user']), 'firstname');
|
||||
ksort(self::$users);
|
||||
foreach(self::$users as $userId => &$userFirstname) {
|
||||
$userFirstname = $userFirstname . ' ' . $this->getData(['user', $userId, 'lastname']);
|
||||
// Les membres ne sont pas éditeurs, les exclure de la liste
|
||||
if ( $this->getData(['user', $userId, 'group']) < self::GROUP_MODERATOR) {
|
||||
unset(self::$users[$userId]);
|
||||
}
|
||||
$userFirstname = $userFirstname . ' ' . $this->getData(['user', $userId, 'lastname']) . ' (' . self::$groupEdits[$this->getData(['user', $userId, 'group'])] . ')';
|
||||
}
|
||||
unset($userFirstname);
|
||||
// Valeurs en sortie
|
||||
@ -417,38 +611,44 @@ class blog extends common {
|
||||
self::$inputNotices['blogArticleCaptcha'] = 'Incorrect';
|
||||
}
|
||||
// Crée le commentaire
|
||||
$commentId = helper::increment(uniqid(), $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment']));
|
||||
$this->setData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment', $commentId, [
|
||||
$commentId = helper::increment(uniqid(), $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment']));
|
||||
$content = $this->getInput('blogArticleContent', false);
|
||||
$this->setData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment', $commentId, [
|
||||
'author' => $this->getInput('blogArticleAuthor', helper::FILTER_STRING_SHORT, empty($this->getInput('blogArticleUserId')) ? TRUE : FALSE),
|
||||
'content' => $this->getInput('blogArticleContent', helper::FILTER_STRING_SHORT, true),
|
||||
'content' => $content,
|
||||
'createdOn' => time(),
|
||||
'userId' => $this->getInput('blogArticleUserId'),
|
||||
'approval' => !$this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'commentApproved']) // true commentaire publié false en attente de publication
|
||||
]]);
|
||||
|
||||
// Envoi d'une notification aux administrateurs
|
||||
// Init tableau
|
||||
$to = [];
|
||||
// Liste des destinataires
|
||||
foreach($this->getData(['user']) as $userId => $user) {
|
||||
if ($user['group'] >= $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'groupNotification']) ) {
|
||||
if ($user['group'] >= $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'commentGroupNotification']) ) {
|
||||
$to[] = $user['mail'];
|
||||
$firstname[] = $user['firstname'];
|
||||
$lastname[] = $user['lastname'];
|
||||
}
|
||||
}
|
||||
// Envoi du mail $sent code d'erreur ou de réussite
|
||||
if ($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'mailNotification']) === true) {
|
||||
$sent = $this->sendMail(
|
||||
$to,
|
||||
'Nouveau commentaire déposé',
|
||||
'Bonjour' . ' <strong>' . $user['firstname'] . ' ' . $user['lastname'] . '</strong>,<br><br>' .
|
||||
'L\'article <a href="' . helper::baseUrl() . $this->getUrl(0) . '/ ' . $this->getUrl(1) . '">' . $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'title']) . '</a> a reçu un nouveau commentaire.<br><br>',
|
||||
''
|
||||
);
|
||||
$notification = $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'commentApproved']) === true ? 'Commentaire déposé en attente d\'approbation': 'Commentaire déposé';
|
||||
if ($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'commentNotification']) === true) {
|
||||
$error = 0;
|
||||
foreach($to as $key => $adress){
|
||||
$sent = $this->sendMail(
|
||||
$adress,
|
||||
'Nouveau commentaire déposé',
|
||||
'Bonjour' . ' <strong>' . $firstname[$key] . ' ' . $lastname[$key] . '</strong>,<br><br>' .
|
||||
'L\'article <a href="' . helper::baseUrl() . $this->getUrl(0) . '/ ' . $this->getUrl(1) . '">' . $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'title']) . '</a> a reçu un nouveau commentaire.<br><br>',
|
||||
''
|
||||
);
|
||||
if( $sent === false) $error++;
|
||||
}
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl() . '#comment',
|
||||
//'notification' => 'Commentaire ajouté',
|
||||
//'state' => true
|
||||
'notification' => ($sent === true ? 'Commentaire ajouté, les administrateurs ont été notifiés.' : 'Commentaire ajouté. <br/>' . $sent),
|
||||
'notification' => ($error === 0 ? $notification . '<br/>Une notification a été envoyée.' : $notification . '<br/> Erreur de notification : ' . $sent),
|
||||
'state' => ($sent === true ? true : null)
|
||||
]);
|
||||
|
||||
@ -456,26 +656,53 @@ class blog extends common {
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl() . '#comment',
|
||||
'notification' => 'Commentaire ajouté',
|
||||
'notification' => $notification,
|
||||
'state' => true
|
||||
]);
|
||||
}
|
||||
|
||||
}
|
||||
// Ids des commentaires par ordre de publication
|
||||
$commentIds = array_keys(helper::arrayCollumn($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment']), 'createdOn', 'SORT_DESC'));
|
||||
// Ids des commentaires approuvés par ordre de publication
|
||||
$commentsApproved = $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment']);
|
||||
if ($commentsApproved) {
|
||||
foreach( $commentsApproved as $key => $value){
|
||||
if($value['approval']===false) unset($commentsApproved[$key]);
|
||||
}
|
||||
// Ligne suivante si affichage du nombre total de commentaires approuvés sous l'article
|
||||
self::$nbCommentsApproved = count($commentsApproved);
|
||||
}
|
||||
$commentIds = array_keys(helper::arrayCollumn($commentsApproved, 'createdOn', 'SORT_DESC'));
|
||||
// Pagination
|
||||
$pagination = helper::pagination($commentIds, $this->getUrl(),$this->getData(['config','itemsperPage']),'#comment');
|
||||
// Liste des pages
|
||||
self::$pages = $pagination['pages'];
|
||||
// Signature de l'article
|
||||
self::$articleSignature = $this->signature($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'userId']));
|
||||
// Signature du commentaire édité
|
||||
if($this->getUser('password') === $this->getInput('ZWII_USER_PASSWORD')) {
|
||||
self::$editCommentSignature = $this->signature($this->getUser('id'));
|
||||
}
|
||||
// Commentaires en fonction de la pagination
|
||||
for($i = $pagination['first']; $i < $pagination['last']; $i++) {
|
||||
self::$comments[$commentIds[$i]] = $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment', $commentIds[$i]]);
|
||||
// Signatures des commentaires
|
||||
$e = $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment', $commentIds[$i],'userId']);
|
||||
if ($e) {
|
||||
self::$commentsSignature[$commentIds[$i]] = $this->signature($e);
|
||||
} else {
|
||||
self::$commentsSignature[$commentIds[$i]] = $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment', $commentIds[$i],'author']);
|
||||
}
|
||||
// Données du commentaire si approuvé
|
||||
if ($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment', $commentIds[$i],'approval']) === true ) {
|
||||
self::$comments[$commentIds[$i]] = $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment', $commentIds[$i]]);
|
||||
}
|
||||
}
|
||||
// Valeurs en sortie
|
||||
$this->addOutput([
|
||||
'showBarEditButton' => true,
|
||||
'title' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'title']),
|
||||
'title' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'title']),
|
||||
'vendor' => [
|
||||
'tinymce'
|
||||
],
|
||||
'view' => 'article'
|
||||
]);
|
||||
}
|
||||
@ -508,4 +735,27 @@ class blog extends common {
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Retourne la signature d'un utilisateur
|
||||
*/
|
||||
private function signature($userId) {
|
||||
switch ($this->getData(['user', $userId, 'signature'])){
|
||||
case 1:
|
||||
return $userId;
|
||||
break;
|
||||
case 2:
|
||||
return $this->getData(['user', $userId, 'pseudo']);
|
||||
break;
|
||||
case 3:
|
||||
return $this->getData(['user', $userId, 'firstname']) . ' ' . $this->getData(['user', $userId, 'lastname']);
|
||||
break;
|
||||
case 4:
|
||||
return $this->getData(['user', $userId, 'lastname']) . ' ' . $this->getData(['user', $userId, 'firstname']);
|
||||
break;
|
||||
default:
|
||||
return $this->getData(['user', $userId, 'firstname']);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -17,3 +17,38 @@ $("#blogAddDraft").on("click", function() {
|
||||
$("#blogAddState").val(0);
|
||||
$("#blogAddForm").trigger("submit");
|
||||
});
|
||||
|
||||
/**
|
||||
* Options de commentaires
|
||||
*/
|
||||
$("#blogAddCommentClose").on("change", function() {
|
||||
if ($(this).is(':checked') ) {
|
||||
$(".commentOptionsWrapper").slideUp();
|
||||
} else {
|
||||
$(".commentOptionsWrapper").slideDown();
|
||||
}
|
||||
});
|
||||
|
||||
$("#blogAddCommentNotification").on("change", function() {
|
||||
if ($(this).is(':checked') ) {
|
||||
$("#blogAddCommentGroupNotification").slideDown();
|
||||
} else {
|
||||
$("#blogAddCommentGroupNotification").slideUp();
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
$( document).ready(function() {
|
||||
|
||||
if ($("#blogAddCloseComment").is(':checked') ) {
|
||||
$(".commentOptionsWrapper").slideUp();
|
||||
} else {
|
||||
$(".commentOptionsWrapper").slideDown();
|
||||
}
|
||||
|
||||
if ($("#blogAddCommentNotification").is(':checked') ) {
|
||||
$("#blogAddCommentGroupNotification").slideDown();
|
||||
} else {
|
||||
$("#blogAddCommentGroupNotification").slideUp();
|
||||
}
|
||||
});
|
@ -68,30 +68,61 @@
|
||||
'class' => 'editorWysiwyg'
|
||||
]); ?>
|
||||
<div class="row">
|
||||
<div class="col6">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Options de publication</h4>
|
||||
<?php echo template::select('blogAddUserId', $module::$users, [
|
||||
'label' => 'Auteur',
|
||||
'selected' => $this->getUser('id')
|
||||
]); ?>
|
||||
<?php echo template::date('blogAddPublishedOn', [
|
||||
'help' => 'L\'article n\'est visible qu\'après la date de publication prévue.',
|
||||
'label' => 'Date de publication',
|
||||
'value' => time()
|
||||
]); ?>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::select('blogAddUserId', $module::$users, [
|
||||
'label' => 'Auteur',
|
||||
'selected' => $this->getUser('id'),
|
||||
'disabled' => $this->getUser('group') !== self::GROUP_ADMIN ? true : false
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::date('blogAddPublishedOn', [
|
||||
'help' => 'L\'article n\'est visible qu\'après la date de publication prévue.',
|
||||
'label' => 'Date de publication',
|
||||
'value' => time()
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::select('blogAddConsent', $module::$articleConsent , [
|
||||
'label' => 'Edition / Suppression',
|
||||
'selected' => $module::EDIT_ALL,
|
||||
'help' => 'Les utilisateurs des groupes supérieurs accèdent à l\'article sans restriction'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col6">
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Options avancées</h4>
|
||||
<?php echo template::checkbox('blogAddCloseComment', true, 'Fermer les commentaires' ); ?>
|
||||
<?php echo template::checkbox('blogAddMailNotification', true, 'Notifier le commentaire aux groupes à partir de :', [
|
||||
'help' => 'Editeurs = éditeurs + administrateurs<br/> Membres = membres + éditeurs + administrateurs'
|
||||
]); ?>
|
||||
<?php echo template::select('blogAddGroupNotification', $module::$groupNews, [
|
||||
'label' => ''
|
||||
]); ?>
|
||||
<h4>Commentaires</h4>
|
||||
<div class="row">
|
||||
<div class="col4 ">
|
||||
<?php echo template::checkbox('blogAddCommentClose', true, 'Fermer les commentaires'); ?>
|
||||
</div>
|
||||
<div class="col4 commentOptionsWrapper ">
|
||||
<?php echo template::checkbox('blogAddCommentApproved', true, 'Approbation par un modérateur'); ?>
|
||||
</div>
|
||||
<div class="col4 commentOptionsWrapper">
|
||||
<?php echo template::select('blogAddCommentMaxlength', $module::$commentLength,[
|
||||
'help' => 'Choix du nombre maximum de caractères pour chaque commentaire de l\'article, mise en forme html comprise.',
|
||||
'label' => 'Caractères par commentaire'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col3 commentOptionsWrapper offset2">
|
||||
<?php echo template::checkbox('blogAddCommentNotification', true, 'Notification par email'); ?>
|
||||
</div>
|
||||
<div class="col4 commentOptionsWrapper">
|
||||
<?php echo template::select('blogAddCommentGroupNotification', $module::$groupNews); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -13,17 +13,35 @@
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<?php if(
|
||||
$this->getUser('group') >= self::GROUP_ADMIN
|
||||
AND $this->getUser('password') === $this->getInput('ZWII_USER_PASSWORD')
|
||||
): ?>
|
||||
<div class="col2">
|
||||
<?php echo template::button('blogEdit', [
|
||||
'href' => helper::baseUrl() . $this->getUrl(0) . '/edit/' . $this->getUrl(1) . '/' . $_SESSION['csrf'],
|
||||
'value' => 'Editer'
|
||||
]); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php if (
|
||||
$this->getUser('password') === $this->getInput('ZWII_USER_PASSWORD')
|
||||
AND
|
||||
( // Propriétaire
|
||||
(
|
||||
$this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1),'editConsent']) === $module::EDIT_OWNER
|
||||
AND ( $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1),'userId']) === $this->getUser('id')
|
||||
OR $this->getUser('group') === self::GROUP_ADMIN )
|
||||
)
|
||||
OR (
|
||||
// Groupe
|
||||
( $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1),'editConsent']) === self::GROUP_ADMIN
|
||||
OR $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1),'editConsent']) === self::GROUP_MODERATOR)
|
||||
AND $this->getUser('group') >= $this->getData(['module',$this->getUrl(0), 'posts', $this->getUrl(1),'editConsent'])
|
||||
)
|
||||
OR (
|
||||
// Tout le monde
|
||||
$this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1),'editConsent']) === $module::EDIT_ALL
|
||||
AND $this->getUser('group') >= $module::$actions['config']
|
||||
)
|
||||
)
|
||||
): ?>
|
||||
<?php echo template::button('blogEdit', [
|
||||
'href' => helper::baseUrl() . $this->getUrl(0) . '/edit/' . $this->getUrl(1) . '/' . $_SESSION['csrf'],
|
||||
'value' => 'Editer'
|
||||
]); ?>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php $pictureSize = $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'pictureSize']) === null ? '100' : $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'pictureSize']); ?>
|
||||
<?php if ($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'hidePicture']) == false) {
|
||||
@ -31,14 +49,9 @@
|
||||
' pict' . $pictureSize . '" src="' . helper::baseUrl(false) . self::FILE_DIR.'source/' . $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'picture']) .
|
||||
'" alt="' . $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'picture']) . '">';
|
||||
} ?>
|
||||
|
||||
<?php echo $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'content']); ?>
|
||||
<p class="clearBoth signature">
|
||||
<?php echo $this->getData(['user', $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'userId']), 'firstname']); ?>
|
||||
<?php echo $this->getData(['user', $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'userId']), 'lastname']); ?>
|
||||
</p>
|
||||
<?php echo template::formClose(); ?>
|
||||
<!-- Bloc RSS-->
|
||||
<?php echo $this->getData(['module', $this->getUrl(0),'posts', $this->getUrl(1), 'content']); ?>
|
||||
<p class="clearBoth signature"><?php echo $module::$articleSignature;?></p>
|
||||
<!-- Bloc RSS-->
|
||||
<?php if ($this->getData(['module',$this->getUrl(0), 'config', 'feeds'])): ?>
|
||||
<div id="rssFeed">
|
||||
<a type="application/rss+xml" href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/rss'; ?> ">
|
||||
@ -49,11 +62,12 @@
|
||||
</a>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php if($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'closeComment'])): ?>
|
||||
<?php if($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'commentClose'])): ?>
|
||||
<p>Cet article ne reçoit pas de commentaire.</p>
|
||||
<?php else: ?>
|
||||
<h3 id="comment">
|
||||
<?php $commentsNb = count($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'comment'])); ?>
|
||||
<?php //$commentsNb = count($module::$comments); ?>
|
||||
<?php $commentsNb = $module::$nbCommentsApproved; ?>
|
||||
<?php $s = $commentsNb === 1 ? '': 's' ?>
|
||||
<?php echo $commentsNb > 0 ? $commentsNb . ' ' . 'commentaire' . $s : 'Pas encore de commentaire'; ?>
|
||||
</h3>
|
||||
@ -63,11 +77,11 @@
|
||||
'readonly' => true
|
||||
]); ?>
|
||||
<div id="blogArticleCommentWrapper" class="displayNone">
|
||||
<?php if($this->getUser('password') === $this->getInput('ZWII_USER_PASSWORD')): ?>
|
||||
<?php if($this->getUser('password') === $this->getInput('ZWII_USER_PASSWORD')): ?>
|
||||
<?php echo template::text('blogArticleUserName', [
|
||||
'label' => 'Nom',
|
||||
'readonly' => true,
|
||||
'value' => $this->getUser('firstname') . ' ' . $this->getUser('lastname')
|
||||
'value' => $module::$editCommentSignature
|
||||
]); ?>
|
||||
<?php echo template::hidden('blogArticleUserId', [
|
||||
'value' => $this->getUser('id')
|
||||
@ -91,9 +105,12 @@
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php echo template::textarea('blogArticleContent', [
|
||||
'label' => 'Commentaire',
|
||||
'maxlength' => '500'
|
||||
'label' => 'Commentaire avec maximum '.$this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'commentMaxlength']).' caractères',
|
||||
'class' => 'editorWysiwygComment',
|
||||
'noDirty' => true,
|
||||
'maxlength' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(1), 'commentMaxlength'])
|
||||
]); ?>
|
||||
<div id="blogArticleContentAlarm"> </div>
|
||||
<?php if($this->getUser('password') !== $this->getInput('ZWII_USER_PASSWORD')): ?>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
@ -123,17 +140,11 @@
|
||||
<div class="col12">
|
||||
<?php foreach($module::$comments as $commentId => $comment): ?>
|
||||
<div class="block">
|
||||
<h4>
|
||||
<?php if($comment['userId']): ?>
|
||||
<?php echo $this->getData(['user', $comment['userId'], 'firstname']) . ' ' . $this->getData(['user', $comment['userId'], 'lastname']); ?>
|
||||
<?php else: ?>
|
||||
<?php echo $comment['author']; ?>
|
||||
<?php endif; ?>
|
||||
le <?php echo mb_detect_encoding(strftime('%d %B %Y - %H:%M', $comment['createdOn']), 'UTF-8', true)
|
||||
<h4><?php echo $module::$commentsSignature[$commentId]; ?>
|
||||
le <?php echo mb_detect_encoding(strftime('%d %B %Y - %H:%M', $comment['createdOn']), 'UTF-8', true)
|
||||
? strftime('%d %B %Y - %H:%M', $comment['createdOn'])
|
||||
: utf8_encode(strftime('%d %B %Y - %H:%M', $comment['createdOn']));
|
||||
?>
|
||||
</h4>
|
||||
?>
|
||||
<?php echo $comment['content']; ?>
|
||||
</div>
|
||||
<?php endforeach; ?>
|
||||
|
@ -10,12 +10,53 @@
|
||||
* @link http://zwiicms.fr/
|
||||
*/
|
||||
|
||||
|
||||
/**
|
||||
* Confirmation de suppression
|
||||
*/
|
||||
$(".blogCommentDelete").on("click", function() {
|
||||
var _this = $(this);
|
||||
return core.confirm("Êtes-vous sûr de vouloir supprimer ce commentaire ?", function() {
|
||||
var nom = "<?php echo $this->getData(['module', $this->getUrl(0), $this->getUrl(2), 'title' ]); ?>";
|
||||
return core.confirm("Supprimer le commentaire de l'article " + nom + " ?", function() {
|
||||
$(location).attr("href", _this.attr("href"));
|
||||
});
|
||||
});
|
||||
|
||||
/**
|
||||
* Confirmation d'approbation
|
||||
*/
|
||||
$(".blogCommentApproved").on("click", function() {
|
||||
var _this = $(this);
|
||||
var nom = "<?php echo $this->getData(['module', $this->getUrl(0), $this->getUrl(2), 'title' ]); ?>";
|
||||
return core.confirm("Approuver le commentaire de l'article " + nom + " ?", function() {
|
||||
$(location).attr("href", _this.attr("href"));
|
||||
});
|
||||
});
|
||||
|
||||
/**
|
||||
* Confirmation de rejet
|
||||
*/
|
||||
$(".blogCommentRejected").on("click", function() {
|
||||
var _this = $(this);
|
||||
var nom = "<?php echo $this->getData(['module', $this->getUrl(0), $this->getUrl(2), 'title' ]); ?>";
|
||||
return core.confirm("Rejeter le commentaire de l'article " + nom + " ?", function() {
|
||||
$(location).attr("href", _this.attr("href"));
|
||||
});
|
||||
});
|
||||
|
||||
/**
|
||||
* Confirmation de suppression en masse
|
||||
*/
|
||||
$(".blogCommentDeleteAll").on("click", function() {
|
||||
var _this = $(this);
|
||||
var nombre = "<?php echo count($this->getData(['module', $this->getUrl(0), $this->getUrl(2), 'comment' ])); ?>";
|
||||
var nom = "<?php echo $this->getData(['module', $this->getUrl(0), $this->getUrl(2), 'title' ]); ?>";
|
||||
if( nombre === "1"){
|
||||
var message = "Supprimer le commentaire de l'article " + nom + " ?";
|
||||
} else{
|
||||
var message = "Supprimer les " + nombre + " commentaires de l'article " + nom + " ?";
|
||||
}
|
||||
return core.confirm(message, function() {
|
||||
$(location).attr("href", _this.attr("href"));
|
||||
});
|
||||
});
|
@ -7,10 +7,16 @@
|
||||
'value' => 'Retour'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php if($module::$comments): ?>
|
||||
<?php echo template::table([3, 6, 2, 1], $module::$comments, ['Date', 'Contenu', 'Auteur', '']); ?>
|
||||
<?php echo $module::$pages; ?>
|
||||
<div class="col2 offset8">
|
||||
<?php echo $module::$commentsDelete; ?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<?php echo template::table([3, 5, 2, 1, 1], $module::$comments, ['Date', 'Contenu', 'Auteur', '', '']); ?>
|
||||
<?php echo $module::$pages.'<br/>'; ?>
|
||||
<?php else: ?>
|
||||
</div>
|
||||
<?php echo template::speech('Aucun commentaire.'); ?>
|
||||
<?php endif; ?>
|
@ -8,13 +8,7 @@
|
||||
'value' => 'Retour'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col3 offset3">
|
||||
<?php echo template::button('blogConfigComment', [
|
||||
'href' => helper::baseUrl() . $this->getUrl(0) . '/comment',
|
||||
'value' => 'Gérer les commentaires'
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col2">
|
||||
<div class="col2 offset6">
|
||||
<?php echo template::button('blogConfigAdd', [
|
||||
'href' => helper::baseUrl() . $this->getUrl(0) . '/add',
|
||||
'ico' => 'plus',
|
||||
@ -45,13 +39,14 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php if($module::$articles): ?>
|
||||
<?php echo template::table([4, 4, 2, 1, 1], $module::$articles, ['Titre', 'Date de publication', 'État', '', '']); ?>
|
||||
<?php echo $module::$pages; ?>
|
||||
<?php else: ?>
|
||||
<?php echo template::speech('Aucun article.'); ?>
|
||||
<?php endif; ?>
|
||||
<?php echo template::formClose(); ?>
|
||||
<div class="moduleVersion">Version n°
|
||||
<?php echo $module::BLOG_VERSION; ?>
|
||||
</div>
|
||||
<?php echo template::formClose(); ?>
|
||||
<?php if($module::$articles): ?>
|
||||
<?php echo template::table([4, 4, 1, 1, 1, 1], $module::$articles, ['Titre', 'Date de publication', 'État', 'Commentaires', '','']); ?>
|
||||
<?php echo $module::$pages; ?>
|
||||
<?php else: ?>
|
||||
<?php echo template::speech('Aucun article.'); ?>
|
||||
<?php endif; ?>
|
||||
<div class="moduleVersion">Version n°
|
||||
<?php echo $module::BLOG_VERSION; ?>
|
||||
</div>
|
||||
|
||||
|
@ -29,3 +29,38 @@ $("#blogEditDraft").on("click", function() {
|
||||
$("#blogEditState").val(0);
|
||||
$("#blogEditForm").trigger("submit");
|
||||
});
|
||||
|
||||
/**
|
||||
* Options de commentaires
|
||||
*/
|
||||
$("#blogEditCommentClose").on("change", function() {
|
||||
if ($(this).is(':checked') ) {
|
||||
$(".commentOptionsWrapper").slideUp();
|
||||
} else {
|
||||
$(".commentOptionsWrapper").slideDown();
|
||||
}
|
||||
});
|
||||
|
||||
$("#blogEditCommentNotification").on("change", function() {
|
||||
if ($(this).is(':checked') ) {
|
||||
$("#blogEditCommentGroupNotification").slideDown();
|
||||
} else {
|
||||
$("#blogEditCommentGroupNotification").slideUp();
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
$( document).ready(function() {
|
||||
|
||||
if ($("#blogEditCloseComment").is(':checked') ) {
|
||||
$(".commentOptionsWrapper").slideUp();
|
||||
} else {
|
||||
$(".commentOptionsWrapper").slideDown();
|
||||
}
|
||||
|
||||
if ($("#blogEditCommentNotification").is(':checked') ) {
|
||||
$("#blogEditCommentGroupNotification").slideDown();
|
||||
} else {
|
||||
$("#blogEditCommentGroupNotification").slideUp();
|
||||
}
|
||||
});
|
@ -21,6 +21,7 @@
|
||||
<?php echo template::submit('blogEditSubmit', [
|
||||
'value' => 'Publier'
|
||||
]); ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
@ -73,35 +74,73 @@
|
||||
'value' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'content'])
|
||||
]); ?>
|
||||
<div class="row">
|
||||
<div class="col6">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Options de publication</h4>
|
||||
<?php echo template::select('blogEditUserId', $module::$users, [
|
||||
'label' => 'Auteur',
|
||||
'selected' => $this->getUser('id')
|
||||
]); ?>
|
||||
<?php echo template::date('blogEditPublishedOn', [
|
||||
'help' => 'L\'article n\'est visible qu\'après la date de publication prévue.',
|
||||
'label' => 'Date de publication',
|
||||
'value' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'publishedOn'])
|
||||
]); ?>
|
||||
<div class="row">
|
||||
<div class="col4">
|
||||
<?php echo template::select('blogEditUserId', $module::$users, [
|
||||
'label' => 'Auteur',
|
||||
'selected' => $this->getUser('id'),
|
||||
'disabled' => $this->getUser('group') !== self::GROUP_ADMIN ? true : false
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::date('blogEditPublishedOn', [
|
||||
'help' => 'L\'article n\'est visible qu\'après la date de publication prévue.',
|
||||
'label' => 'Date de publication',
|
||||
'value' => time()
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4">
|
||||
<?php echo template::select('blogEditConsent', $module::$articleConsent , [
|
||||
'label' => 'Edition / Suppression',
|
||||
'selected' => is_numeric($this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'editConsent'])) ? $module::EDIT_GROUP : $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'editConsent']),
|
||||
'help' => 'Les utilisateurs des groupes supérieurs accèdent à l\'article sans restriction'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col6">
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<div class="block">
|
||||
<h4>Options avancées</h4>
|
||||
<?php echo template::checkbox('blogEditCloseComment', true, 'Fermer les commentaires', [
|
||||
'checked' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'closeComment'])
|
||||
]); ?>
|
||||
<?php echo template::checkbox('blogEditMailNotification', true, 'Notifier le commentaire aux groupes à partir de :', [
|
||||
'checked' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'mailNotification']),
|
||||
'help' => 'Editeurs = éditeurs + administrateurs<br/> Membres = membres + éditeurs + administrateurs'
|
||||
<h4>Commentaires</h4>
|
||||
<div class="row">
|
||||
<div class="col4 ">
|
||||
<?php echo template::checkbox('blogEditCommentClose', true, 'Fermer les commentaires', [
|
||||
'checked' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'commentClose'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 commentOptionsWrapper ">
|
||||
<?php echo template::checkbox('blogEditCommentApproved', true, 'Approbation par un modérateur', [
|
||||
'checked' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'commentApproved']),
|
||||
''
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 commentOptionsWrapper">
|
||||
<?php echo template::select('blogEditCommentMaxlength', $module::$commentLength,[
|
||||
'help' => 'Choix du nombre maximum de caractères pour chaque commentaire de l\'article, mise en forme html comprise.',
|
||||
'label' => 'Caractères par commentaire',
|
||||
'selected' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'commentMaxlength'])
|
||||
]); ?>
|
||||
</div>
|
||||
|
||||
]); ?>
|
||||
<?php echo template::select('blogEditGroupNotification', $module::$groupNews, [
|
||||
'label' => '',
|
||||
'selected' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'groupNotification'])
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col3 commentOptionsWrapper offset2">
|
||||
<?php echo template::checkbox('blogEditCommentNotification', true, 'Notification par email', [
|
||||
'checked' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'commentNotification']),
|
||||
]); ?>
|
||||
</div>
|
||||
<div class="col4 commentOptionsWrapper">
|
||||
<?php echo template::select('blogEditCommentGroupNotification', $module::$groupNews, [
|
||||
'selected' => $this->getData(['module', $this->getUrl(0), 'posts', $this->getUrl(2), 'commentGroupNotification']),
|
||||
'help' => 'Editeurs = éditeurs + administrateurs<br/> Membres = membres + éditeurs + administrateurs'
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -21,6 +21,7 @@
|
||||
</a>
|
||||
</div>
|
||||
<div class="col9">
|
||||
<article>
|
||||
<h1 class="blogTitle">
|
||||
<a href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/' . $articleId; ?>">
|
||||
<?php echo $article['title']; ?>
|
||||
@ -28,7 +29,9 @@
|
||||
</h1>
|
||||
<div class="blogComment">
|
||||
<a href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/' . $articleId; ?>#comment">
|
||||
<?php echo count($article['comment']); ?>
|
||||
<?php if ($article['comment']): ?>
|
||||
<?php echo count($article['comment']); ?>
|
||||
<?php endif; ?>
|
||||
</a>
|
||||
<?php echo template::ico('comment', 'left'); ?>
|
||||
</div>
|
||||
@ -42,6 +45,7 @@
|
||||
<?php echo helper::subword(strip_tags($article['content']), 0, 400); ?>...
|
||||
<a href="<?php echo helper::baseUrl() . $this->getUrl(0) . '/' . $articleId; ?>">Lire la suite</a>
|
||||
</p>
|
||||
</article>
|
||||
</div>
|
||||
</div>
|
||||
<?php endforeach; ?>
|
||||
|
@ -32,7 +32,7 @@ class form extends common {
|
||||
|
||||
public static $pagination;
|
||||
|
||||
const FORM_VERSION = '2.5';
|
||||
const FORM_VERSION = '2.6';
|
||||
|
||||
// Objets
|
||||
const TYPE_MAIL = 'mail';
|
||||
@ -94,7 +94,7 @@ class form extends common {
|
||||
$inputs = [];
|
||||
foreach($this->getInput('formConfigPosition', null) as $index => $position) {
|
||||
$inputs[] = [
|
||||
'name' => $this->getInput('formConfigName[' . $index . ']'),
|
||||
'name' => htmlspecialchars_decode($this->getInput('formConfigName[' . $index . ']'),ENT_QUOTES),
|
||||
'position' => helper::filter($position, helper::FILTER_INT),
|
||||
'required' => $this->getInput('formConfigRequired[' . $index . ']', helper::FILTER_BOOLEAN),
|
||||
'type' => $this->getInput('formConfigType[' . $index . ']'),
|
||||
|
@ -45,7 +45,7 @@
|
||||
<?php endforeach; ?>
|
||||
<?php if($this->getData(['module', $this->getUrl(0), 'config', 'captcha'])): ?>
|
||||
<div class="row">
|
||||
<div class="col5">
|
||||
<div class="col12 textAlignCenter">
|
||||
<?php echo template::captcha('formCaptcha', [
|
||||
'limit' => $this->getData(['config','captchaStrong'])
|
||||
]); ?>
|
||||
|
@ -33,7 +33,7 @@ class news extends common {
|
||||
false => 'Brouillon',
|
||||
true => 'Publié'
|
||||
];
|
||||
const NEWS_VERSION = '1.3';
|
||||
const NEWS_VERSION = '2.0';
|
||||
|
||||
public static $users = [];
|
||||
|
||||
@ -53,11 +53,11 @@ class news extends common {
|
||||
$feeds = new \FeedWriter\RSS2();
|
||||
|
||||
// En-tête
|
||||
$feeds->setTitle($this->getData (['page', $this->getUrl(0),'posts','title']));
|
||||
$feeds->setTitle($this->getData (['page', $this->getUrl(0),'title']));
|
||||
$feeds->setLink(helper::baseUrl() . $this->getUrl(0));
|
||||
$feeds->setDescription(html_entity_decode(strip_tags($this->getData (['page', $this->getUrl(0), 'metaDescription']))));
|
||||
$feeds->setDescription($this->getData (['page', $this->getUrl(0), 'metaDescription']));
|
||||
$feeds->setChannelElement('language', 'fr-FR');
|
||||
$feeds->setDate(time());
|
||||
$feeds->setDate(date('r',time()));
|
||||
$feeds->addGenerator();
|
||||
// Corps des articles
|
||||
$newsIdsPublishedOns = helper::arrayCollumn($this->getData(['module', $this->getUrl(0), 'posts']), 'publishedOn', 'SORT_DESC');
|
||||
@ -67,11 +67,15 @@ class news extends common {
|
||||
foreach($newsIdsPublishedOns as $newsId => $newsPublishedOn) {
|
||||
if($newsPublishedOn <= time() AND $newsIdsStates[$newsId]) {
|
||||
$newsArticle = $feeds->createNewItem();
|
||||
$author = $this->signature($this->getData(['module', $this->getUrl(0), 'posts', $newsId, 'userId']));
|
||||
$newsArticle->addElementArray([
|
||||
'title' => strip_tags($this->getData(['module', $this->getUrl(0),'posts', $newsId, 'title']) ),
|
||||
'link' => helper::baseUrl() . $this->getUrl(0),
|
||||
'description' => html_entity_decode(strip_tags($this->getData(['module', $this->getUrl(0),'posts', $newsId, 'content'])))
|
||||
'title' => $this->getData(['module', $this->getUrl(0),'posts', $newsId, 'title']),
|
||||
'link' => helper::baseUrl() . $this->getUrl(0) . '/' . $newsId . '#' . $newsId,
|
||||
'description' => $this->getData(['module', $this->getUrl(0),'posts', $newsId, 'content'])
|
||||
]);
|
||||
$newsArticle->setAuthor($author,'no@mail.com');
|
||||
$newsArticle->setId(helper::baseUrl() .$this->getUrl(0) . '/' . $newsId . '#' . $newsId);
|
||||
$newsArticle->setDate(date('r', $this->getData(['module', $this->getUrl(0), 'posts', $newsId, 'publishedOn'])));
|
||||
$feeds->addItem($newsArticle);
|
||||
}
|
||||
}
|
||||
@ -302,4 +306,26 @@ class news extends common {
|
||||
'view' => 'index'
|
||||
]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retourne la signature d'un utilisateur
|
||||
*/
|
||||
private function signature($userId) {
|
||||
switch ($this->getData(['user', $userId, 'signature'])){
|
||||
case 1:
|
||||
return $userId;
|
||||
break;
|
||||
case 2:
|
||||
return $this->getData(['user', $userId, 'pseudo']);
|
||||
break;
|
||||
case 3:
|
||||
return $this->getData(['user', $userId, 'firstname']) . ' ' . $this->getData(['user', $userId, 'lastname']);
|
||||
break;
|
||||
case 4:
|
||||
return $this->getData(['user', $userId, 'lastname']) . ' ' . $this->getData(['user', $userId, 'firstname']);
|
||||
break;
|
||||
default:
|
||||
return $this->getData(['user', $userId, 'firstname']);
|
||||
}
|
||||
}
|
||||
}
|
@ -2,7 +2,7 @@
|
||||
<div class="row">
|
||||
<div class="col12">
|
||||
<?php foreach($module::$news as $newsId => $news): ?>
|
||||
<h1 class="newsTitle">
|
||||
<h1 class="newsTitle" id="<?php echo $newsId;?>">
|
||||
<?php echo $news['title']; ?>
|
||||
</h1>
|
||||
<div class="newsContent">
|
||||
|
@ -1,14 +1,10 @@
|
||||
<?php
|
||||
class theme extends search {
|
||||
public static $defaultData = [
|
||||
'keywordColor' => 'rgba(229, 229, 1, 1)'
|
||||
];
|
||||
}
|
||||
class data extends search {
|
||||
class init extends search {
|
||||
public static $defaultData = [
|
||||
'previewLength' => 100,
|
||||
'resultHideContent' => false,
|
||||
'placeHolder' => 'Un ou plusieurs mots-clés séparés par un espace ou par +',
|
||||
'submitText' => 'Rechercher'
|
||||
'submitText' => 'Rechercher',
|
||||
'keywordColor' => 'rgba(229, 229, 1, 1)'
|
||||
];
|
||||
}
|
@ -1,11 +0,0 @@
|
||||
.searchTitle {
|
||||
font: caption;
|
||||
font-style: italic;
|
||||
margin-left: 1em;
|
||||
}
|
||||
.searchKeyword {
|
||||
background: var(--keywordColor);
|
||||
}
|
||||
.searchResult {
|
||||
margin: .3em 0 .3em 1em;
|
||||
}
|
@ -1,3 +0,0 @@
|
||||
.searchKeyword {
|
||||
--keywordColor: #keywordColor#;
|
||||
}
|
@ -38,37 +38,31 @@ class search extends common {
|
||||
400 => '400 caractères',
|
||||
];
|
||||
|
||||
// Message par défaut
|
||||
public static $messagePlaceHolder = 'Un ou plusieurs mots-clés entre des espaces ou des guillemets';
|
||||
public static $messageButtontext = 'Rechercher';
|
||||
|
||||
const SEARCH_VERSION = '1.1';
|
||||
const SEARCH_VERSION = '1.2';
|
||||
|
||||
// Configuration vide
|
||||
public function config() {
|
||||
// Initialisation des données de thème de la galerie dasn theme.json
|
||||
// Création des valeurs de réglage par défaut
|
||||
if ( $this->getData(['module', $this->getUrl(0)]) === null ) {
|
||||
require_once('module/search/ressource/defaultdata.php');
|
||||
$this->setData(['module', $this->getUrl(0), init::$defaultData]);
|
||||
}
|
||||
|
||||
if($this->isPost()) {
|
||||
// Soumission du formulaire
|
||||
$this->setData(['theme', 'search', [
|
||||
'keywordColor' => $this->getInput('searchKeywordColor')
|
||||
]]);
|
||||
$this->setData(['module', $this->getUrl(0), [
|
||||
'submitText' => $this->getInput('searchSubmitText'),
|
||||
'placeHolder' => $this->getInput('searchPlaceHolder'),
|
||||
'resultHideContent' => $this->getInput('searchResultHideContent',helper::FILTER_BOOLEAN),
|
||||
'previewLength' => $this->getInput('searchPreviewLength',helper::FILTER_INT)
|
||||
'previewLength' => $this->getInput('searchPreviewLength',helper::FILTER_INT),
|
||||
'keywordColor' => $this->getInput('searchKeywordColor')
|
||||
]]);
|
||||
// Création des fichiers CSS
|
||||
$content = file_get_contents('module/search/ressource/vartheme.css');
|
||||
$themeCss = file_get_contents('module/search/ressource/theme.css');
|
||||
// Injection des variables
|
||||
$content = str_replace('#keywordColor#',$this->getinput('searchKeywordColor'),$content );
|
||||
$success = file_put_contents('module/search/view/index/index.css',$content . $themeCss);
|
||||
|
||||
|
||||
// Valeurs en sortie, affichage du formulaire
|
||||
$this->addOutput([
|
||||
'redirect' => helper::baseUrl() . $this->getUrl(),
|
||||
'notification' => $success !== FALSE ? 'Modifications enregistrées' : 'Modifications non enregistées !',
|
||||
'notification' => $success !== FALSE ? 'Modifications enregistrées' : 'Modifications non enregistrées !',
|
||||
'state' => $success !== FALSE
|
||||
]);
|
||||
|
||||
@ -84,15 +78,11 @@ class search extends common {
|
||||
}
|
||||
|
||||
public function index() {
|
||||
// Création des valeurs de thème par défaut
|
||||
if ( $this->getData(['theme', 'search']) === null ) {
|
||||
require_once('module/search/ressource/defaultdata.php');
|
||||
$this->setData(['theme', 'search', theme::$defaultData]);
|
||||
}
|
||||
|
||||
// Création des valeurs de réglage par défaut
|
||||
if ( $this->getData(['module', 'search']) === null ) {
|
||||
if ( $this->getData(['module', $this->getUrl(0)]) === null ) {
|
||||
require_once('module/search/ressource/defaultdata.php');
|
||||
$this->setData(['module', $this->getUrl(0), data::$defaultData]);
|
||||
$this->setData(['module', $this->getUrl(0), init::$defaultData]);
|
||||
}
|
||||
|
||||
if($this->isPost()) {
|
||||
@ -241,7 +231,7 @@ class search extends common {
|
||||
// Découper l'aperçu
|
||||
$t = substr($contenu, $d ,$this->getData(['module',$this->getUrl(0),'previewLength']));
|
||||
// Applique une mise en évidence
|
||||
$t = preg_replace($keywords, '<span class="searchKeyword">\1</span>',$t);
|
||||
$t = preg_replace($keywords, '<span style="background:' . $this->getData(['module',$this->getUrl(0),'keywordColor']). ';">\1</span>',$t);
|
||||
// Sauver résultat
|
||||
$resultat .= '<p class="searchResult">'.$t.'...</p>';
|
||||
$resultat .= '<p class="searchTitle">' . count($matches[0]) . (count($matches[0]) === 1 ? ' correspondance<p>' : ' correspondances<p>');
|
||||
|
@ -59,7 +59,7 @@
|
||||
'class' => 'colorPicker',
|
||||
'help' => 'Le curseur horizontal règle le niveau de transparence, le placer tout à la gauche pour un surlignement invisible.',
|
||||
'label' => 'Surlignement',
|
||||
'value' => $this->getData(['theme', 'search', 'keywordColor'])
|
||||
'value' => $this->getData(['module', $this->getUrl(0), 'keywordColor'])
|
||||
]); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1,14 +1,10 @@
|
||||
.searchKeyword {
|
||||
--keywordColor: rgba(229, 229, 1, 1);
|
||||
}
|
||||
|
||||
.searchTitle {
|
||||
font: caption;
|
||||
font-style: italic;
|
||||
margin-left: 1em;
|
||||
}
|
||||
.searchKeyword {
|
||||
background: var(--keywordColor);
|
||||
}
|
||||
|
||||
.searchResult {
|
||||
margin: .3em 0 .3em 1em;
|
||||
}
|