Deltacms/core/module/theme/view/footer/footer.php

407 lines
18 KiB
PHP
Raw Normal View History

2022-03-06 13:35:21 +01:00
<?php
// Lexique
$text = [];
$val = $this->getData(['config', 'i18n', 'langAdmin']);
switch ($val) {
case 'fr' :
$text[0] = 'Retour';
$text[1] = 'Aide';
$text[2] = 'Enregistrer';
$text[3] = 'Paramètres';
$text[4] = 'Position';
$text[5] = 'Marges verticales';
$text[6] = 'Couleurs';
$text[7] = 'Texte';
$text[8] = 'Arrière-plan';
$text[9] = 'Quand le pied de page est dans le site, l\'arrière plan transparent montre le fond de la page. Quand le pied de page est hors du site, l\'arrière plan transparent montre le fond du site.';
$text[10] = 'Contenu';
$text[11] = 'Motorisé par';
$text[12] = 'Affiche cette mention devant DeltaCMS';
$text[13] = 'Version';
$text[14] = 'Affiche le numéro de version après DeltaCMS';
$text[15] = 'Plan du site';
$text[16] = 'Cookies';
$text[17] = 'Message d\'information relatif aux cookies, disponible si l\'acceptation des cookies est activé.';
$text[18] = 'Lien de connexion';
$text[19] = 'Pour limiter les tentatives de piratage, enregistrez la page de connexion en favori et désactivez cette option.';
$text[20] = 'Barre du membre';
$text[21] = 'Affiche les icônes de gestion du compte et de déconnexion des membres simples connectés, ne s\'applique pas aux éditeurs et administrateurs.';
$text[22] = 'Mentions légales';
$text[23] = 'Option active si une page a été sélectionnée.';
$text[24] = 'Aucune';
$text[25] = 'Page "Mentions légales" ';
$text[26] = 'Rechercher';
$text[27] = 'Option active si une page a été sélectionnée.';
$text[28] = 'Page "Rechercher" ';
$text[29] = 'Options identique à la configuration du site';
$text[30] = 'Mise en forme du texte';
$text[31] = 'Police';
$text[32] = 'Taille';
$text[33] = 'Proportionnelle à celle définie dans le site.';
$text[34] = 'Style';
$text[35] = 'Casse';
$text[36] = 'Dispositions';
$text[37] = 'Répartition';
$text[38] = 'Contenu personnalisé';
$text[39] = 'Position';
$text[40] = 'Alignement';
$text[41] = 'Réseaux sociaux';
$text[42] = 'Informations';
$text[43] = 'Alignement avec le contenu';
$text[44] = 'Pied de page fixe';
$text[45] = 'Contenu personnalisé';
$footerPositions = $module::$footerPositions;
$footerHeights = $module::$footerHeights;
$footerFontSizes = $module::$footerFontSizes;
$fontWeights = $module::$fontWeights;
$textTransforms = $module::$textTransforms;
$footerblocks = $module::$footerblocks;
$footerTemplate = $module::$footerTemplate;
$aligns = $module::$aligns;
break;
case 'en' :
$text[0] = 'Back';
$text[1] = 'Help';
$text[2] = 'Save';
$text[3] = 'Settings';
$text[4] = 'Position';
$text[5] = 'Vertical margins';
$text[6] = 'Colours';
$text[7] = 'Text';
$text[8] = 'Background';
$text[9] = 'When the footer is inside the site, the transparent background shows the page background. When the footer is outside the site, the transparent background shows the site background';
$text[10] = 'Content';
$text[11] = 'Powered by';
$text[12] = 'Displays this in front of DeltaCMS';
$text[13] = 'Version';
$text[14] = 'Displays the version number after DeltaCMS';
$text[15] = 'Site map';
$text[16] = 'Cookies';
$text[17] = 'Cookie information message, available if cookie acceptance is enabled';
$text[18] = 'Login link';
$text[19] = 'To limit hacking attempts, save the login page as a favourite and disable this option';
$text[20] = 'Member bar';
$text[21] = 'Displays account management and logout icons for simple logged-in members, does not apply to editors and administrators';
$text[22] = 'Legal notice';
$text[23] = 'Option active if a page has been selected';
$text[24] = 'None';
$text[25] = 'Legal page ';
$text[26] = 'Search';
$text[27] = 'Option active if a page has been selected';
$text[28] = 'Search page ';
$text[29] = 'Options same as site configuration';
$text[30] = 'Text formatting';
$text[31] = 'Font';
$text[32] = 'Size';
$text[33] = 'Proportional to that defined in the site';
$text[34] = 'Style';
$text[35] = 'Character case';
$text[36] = 'Layout';
$text[37] = 'Breakdown';
$text[38] = 'Custom content';
$text[39] = 'Position';
$text[40] = 'Alignment';
$text[41] = 'Social networks';
$text[42] = 'Information';
$text[43] = 'Alignment with content';
$text[44] = 'Fixed footer';
$text[45] = 'Customised content';
$footerPositions = $module::$footerPositions_en;
$footerHeights = $module::$footerHeights_en;
$footerFontSizes = $module::$footerFontSizes_en;
$fontWeights = $module::$fontWeights_en;
$textTransforms = $module::$textTransforms_en;
$footerblocks = $module::$footerblocks_en;
$footerTemplate = $module::$footerTemplate_en;
$aligns = $module::$aligns_en;
break;
}
?>
2022-01-31 09:10:49 +01:00
<?php echo template::formOpen('themeFooterForm'); ?>
<div class="row">
<div class="col2">
<?php echo template::button('themeFooterBack', [
'class' => 'buttonGrey',
'href' => helper::baseUrl() . 'theme',
'ico' => 'left',
2022-03-06 13:35:21 +01:00
'value' => $text[0]
2022-01-31 09:10:49 +01:00
]); ?>
</div>
<div class="col2">
<?php echo template::button('themeFooterHelp', [
'href' => 'https://doc.deltacms.fr/personnalisation-du-pied-de-page',
'target' => '_blank',
'ico' => 'help',
2022-03-06 13:35:21 +01:00
'value' => $text[1],
2022-01-31 09:10:49 +01:00
'class' => 'buttonHelp'
]); ?>
</div>
<div class="col2 offset6">
2022-03-06 13:35:21 +01:00
<?php echo template::submit('themeFooterSubmit',[
'value' => $text[2]
]); ?>
2022-01-31 09:10:49 +01:00
</div>
</div>
<div class="row">
<div class="col12">
<div class="block">
2022-03-06 13:35:21 +01:00
<h4><?php echo $text[3]; ?></h4>
2022-01-31 09:10:49 +01:00
<div class="row">
<div class="col6">
2022-03-06 13:35:21 +01:00
<?php echo template::select('themeFooterPosition', $footerPositions, [
'label' => $text[4],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'position'])
]); ?>
</div>
<div class="col6">
2022-03-06 13:35:21 +01:00
<?php echo template::select('themeFooterHeight', $footerHeights, [
'label' => $text[5],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'height'])
]); ?>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col12">
<div class="block">
2022-03-06 13:35:21 +01:00
<h4><?php echo $text[6]; ?></h4>
2022-01-31 09:10:49 +01:00
<div class="row">
<div class="col6">
<?php echo template::text('themeFooterTextColor', [
'class' => 'colorPicker',
2022-03-06 13:35:21 +01:00
'label' => $text[7],
2022-01-31 09:10:49 +01:00
'value' => $this->getData(['theme', 'footer', 'textColor'])
]); ?>
</div>
<div class="col6">
<?php echo template::text('themeFooterBackgroundColor', [
'class' => 'colorPicker',
2022-03-06 13:35:21 +01:00
'label' => $text[8],
2022-01-31 09:10:49 +01:00
'value' => $this->getData(['theme', 'footer', 'backgroundColor']),
2022-03-06 13:35:21 +01:00
'help' => $text[9]
2022-01-31 09:10:49 +01:00
]); ?>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col12">
<div class="block">
2022-03-06 13:35:21 +01:00
<h4><?php echo $text[10]; ?></h4>
2022-01-31 09:10:49 +01:00
<div class="row">
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::checkbox('themefooterDisplayCopyright', true, $text[11], [
2022-01-31 09:10:49 +01:00
'checked' => $this->getData(['theme', 'footer','displayCopyright']),
2022-03-06 13:35:21 +01:00
'help' => $text[12]
2022-01-31 09:10:49 +01:00
]); ?>
</div>
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::checkbox('themefooterDisplayVersion', true, $text[13], [
2022-01-31 09:10:49 +01:00
'checked' => $this->getData(['theme', 'footer','displayVersion']),
2022-03-06 13:35:21 +01:00
'help' => $text[14]
2022-01-31 09:10:49 +01:00
]); ?>
</div>
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::checkbox('themefooterDisplaySiteMap', true, $text[15], [
2022-01-31 09:10:49 +01:00
'checked' => $this->getData(['theme', 'footer', 'displaySiteMap'])
]); ?>
</div>
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::checkbox('themefooterDisplayCookie', true, $text[16], [
2022-01-31 09:10:49 +01:00
'checked' => $this->getData(['config', 'cookieConsent']) === true ? $this->getData(['theme', 'footer', 'displayCookie']) : false,
2022-03-06 13:35:21 +01:00
'help' => $text[17],
2022-01-31 09:10:49 +01:00
'disabled' => !$this->getData(['config', 'cookieConsent'])
]); ?>
</div>
</div>
<div class="row">
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::checkbox('themeFooterLoginLink', true, $text[18], [
2022-01-31 09:10:49 +01:00
'checked' => $this->getData(['theme', 'footer', 'loginLink']),
2022-03-06 13:35:21 +01:00
'help' => $text[19]
2022-01-31 09:10:49 +01:00
]); ?>
</div>
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::checkbox('themeFooterDisplayMemberBar', true, $text[20], [
2022-01-31 09:10:49 +01:00
'checked' => $this->getData(['theme', 'footer', 'displayMemberBar']),
2022-03-06 13:35:21 +01:00
'help' => $text[21]
2022-01-31 09:10:49 +01:00
]); ?>
</div>
</div>
<div class="row">
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::checkbox('themeFooterDisplayLegal', true, $text[22], [
2022-01-31 09:10:49 +01:00
'checked' => $this->getData(['locale', 'legalPageId']) === 'none' ? false : $this->getData(['theme', 'footer', 'displayLegal']),
'disabled' => $this->getData(['locale', 'legalPageId']) === 'none' ? true : false,
2022-03-06 13:35:21 +01:00
'help' => $text[23]
2022-01-31 09:10:49 +01:00
]); ?>
</div>
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php // drapeau pour la langue d'origine ou la langue en traduction rédigée
$flag = 'site';
if( $this->getInput('DELTA_I18N_SITE') === 'base') $flag = $this->getData(['config', 'i18n', 'langBase']); ?>
<?php echo template::select('configLegalPageId', array_merge(['none' => $text[24]] , helper::arrayCollumn($module::$pagesList, 'title', 'SORT_ASC') ) , [
'label' => $text[25] . template::flag($flag, '20px'),
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['locale', 'legalPageId'])
]); ?>
</div>
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::checkbox('themeFooterDisplaySearch', true, $text[26], [
2022-01-31 09:10:49 +01:00
'checked' => $this->getData(['locale', 'searchPageId']) === 'none' ? false : $this->getData(['theme', 'footer', 'displaySearch']),
'disabled' => $this->getData(['locale', 'searchPageId']) === 'none' ? true : false,
2022-03-06 13:35:21 +01:00
'help' => $text[27]
2022-01-31 09:10:49 +01:00
]); ?>
</div>
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::select('configSearchPageId', array_merge(['none' => $text[24]] , helper::arrayCollumn($module::$pagesList, 'title', 'SORT_ASC') ) , [
'label' => $text[28] . template::flag($flag, '20px'),
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['locale', 'searchPageId']),
2022-03-06 13:35:21 +01:00
'help' => $text[29]
2022-01-31 09:10:49 +01:00
]); ?>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col12">
<?php echo template::textarea('themeFooterText', [
2022-03-06 13:35:21 +01:00
'label' => '<div class="titleWysiwygContent">'.$text[45].'</div>',
2022-01-31 09:10:49 +01:00
'value' => $this->getData(['theme', 'footer', 'text']),
'class' => 'editorWysiwyg'
]); ?>
</div>
</div>
<div class="row">
<div class="col12">
<div class="block">
2022-03-06 13:35:21 +01:00
<h4><?php echo $text[30]; ?></h4>
2022-01-31 09:10:49 +01:00
<div class="row">
<div class="col3">
<?php echo template::select('themeFooterFont', $module::$fonts, [
2022-03-06 13:35:21 +01:00
'label' => $text[31],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'font']),
'fonts' => true
]); ?>
</div>
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::select('themeFooterFontSize', $footerFontSizes, [
'label' => $text[32],
'help' => $text[33],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'fontSize'])
]); ?>
</div>
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::select('themeFooterFontWeight', $fontWeights, [
'label' => $text[34],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'fontWeight'])
]); ?>
</div>
<div class="col3">
2022-03-06 13:35:21 +01:00
<?php echo template::select('themeFooterTextTransform', $textTransforms, [
'label' => $text[35],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'textTransform'])
]); ?>
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col12">
<div class="block">
2022-03-06 13:35:21 +01:00
<h4><?php echo $text[36]; ?></h4>
2022-01-31 09:10:49 +01:00
<div class="row">
<div class="col4">
2022-03-06 13:35:21 +01:00
<?php $footerBlockPosition = is_null($this->getData(['theme', 'footer', 'template'])) ? $footerblocks[3] : $footerblocks [$this->getData(['theme', 'footer', 'template'])] ;?>
<?php echo template::select('themeFooterTemplate', $footerTemplate, [
'label' => $text[37],
2022-01-31 09:10:49 +01:00
'selected' => is_null($this->getData(['theme', 'footer', 'template'])) ? 4 : $this->getData(['theme', 'footer', 'template'])
]); ?>
</div>
</div>
<div class="row">
<div class="col4">
2022-03-06 13:35:21 +01:00
<p><strong><?php echo $text[38]; ?></strong></p>
2022-01-31 09:10:49 +01:00
<div class="row">
<div class="col12">
<?php echo template::select('themeFooterTextPosition', $footerBlockPosition, [
2022-03-06 13:35:21 +01:00
'label' => $text[39],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'textPosition']),
'class' => 'themeFooterContent'
]); ?>
</div>
</div>
<div class="row">
<div class="col12">
2022-03-06 13:35:21 +01:00
<?php echo template::select('themeFooterTextAlign', $aligns, [
'label' => $text[40],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'textAlign'])
]); ?>
</div>
</div>
</div>
<div class="col4">
2022-03-06 13:35:21 +01:00
<p><strong><?php echo $text[41]; ?></strong></p>
2022-01-31 09:10:49 +01:00
<div class="row">
<div class="col12">
<?php echo template::select('themeFooterSocialsPosition', $footerBlockPosition, [
2022-03-06 13:35:21 +01:00
'label' => $text[39],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'socialsPosition']),
'class' => 'themeFooterContent'
]); ?>
</div>
</div>
<div class="row">
<div class="col12">
2022-03-06 13:35:21 +01:00
<?php echo template::select('themeFooterSocialsAlign', $aligns, [
'label' => $text[40],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'socialsAlign'])
]); ?>
</div>
</div>
</div>
<div class="col4">
2022-03-06 13:35:21 +01:00
<p><strong><?php echo $text[42]; ?></strong></p>
2022-01-31 09:10:49 +01:00
<div class="row">
<div class="col12">
<?php echo template::select('themeFooterCopyrightPosition', $footerBlockPosition, [
2022-03-06 13:35:21 +01:00
'label' => $text[39],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'copyrightPosition']),
'class' => 'themeFooterContent'
]); ?>
</div>
</div>
<div class="row">
<div class="col12">
2022-03-06 13:35:21 +01:00
<?php echo template::select('themeFooterCopyrightAlign', $aligns, [
'label' => $text[40],
2022-01-31 09:10:49 +01:00
'selected' => $this->getData(['theme', 'footer', 'copyrightAlign'])
]); ?>
</div>
</div>
</div>
<div class="col6">
<div id="themeFooterPositionOptions">
2022-03-06 13:35:21 +01:00
<?php echo template::checkbox('themeFooterMargin', true, $text[43], [
2022-01-31 09:10:49 +01:00
'checked' => $this->getData(['theme', 'footer', 'margin'])
]); ?>
</div>
</div>
<div class="col6">
<div id="themeFooterPositionFixed" class="displayNone">
2022-03-06 13:35:21 +01:00
<?php echo template::checkbox('themeFooterFixed', true, $text[44], [
2022-01-31 09:10:49 +01:00
'checked' => $this->getData(['theme', 'footer', 'fixed'])
]); ?>
</div>
</div>
</div>
</div>
</div>
</div>
<?php echo template::formClose(); ?>