factorisation: site_lang, posts_per_page, site_license, contact dynamique
This commit is contained in:
+13
-13
@@ -1,5 +1,5 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="fr">
|
||||
<html lang="<?= htmlspecialchars(siteLang()) ?>">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title><?= htmlspecialchars(($seoTitle ?? '') ?: ($title ?? siteTitle())) ?></title>
|
||||
@@ -14,7 +14,7 @@
|
||||
<meta property="og:title" content="<?= htmlspecialchars(($seoTitle ?? '') ?: ($title ?? siteTitle())) ?>">
|
||||
<meta property="og:description" content="<?= htmlspecialchars(($seoDescription ?? '') ?: siteClaim()) ?>">
|
||||
<meta property="og:type" content="<?= htmlspecialchars($ogType ?? 'website') ?>">
|
||||
<meta property="og:locale" content="fr_FR">
|
||||
<meta property="og:locale" content="<?= htmlspecialchars(siteLangOgLocale()) ?>">
|
||||
<meta property="og:url" content="<?= htmlspecialchars($ogUrl ?? APP_URL) ?>">
|
||||
<meta property="og:site_name" content="<?= htmlspecialchars(siteTitle()) ?>">
|
||||
<?php if (!empty($ogImage ?? '')): ?>
|
||||
@@ -56,16 +56,16 @@
|
||||
<div class="container-fluid">
|
||||
<?php
|
||||
$_layoutAction = $_GET['action'] ?? 'list';
|
||||
$_layoutPrivateCats = isset($articles) ? $articles->getPrivateCategories() : [];
|
||||
$_layoutCats = isset($articles) ? array_filter(
|
||||
$articles->getCategories(),
|
||||
function ($cat) use ($_layoutPrivateCats) {
|
||||
return isLoggedIn() || !in_array($cat, $_layoutPrivateCats, true);
|
||||
},
|
||||
ARRAY_FILTER_USE_KEY
|
||||
) : [];
|
||||
$_layoutCurrentCat = trim($_GET['cat'] ?? '');
|
||||
?>
|
||||
$_layoutPrivateCats = isset($articles) ? $articles->getPrivateCategories() : [];
|
||||
$_layoutCats = isset($articles) ? array_filter(
|
||||
$articles->getCategories(),
|
||||
function ($cat) use ($_layoutPrivateCats) {
|
||||
return isLoggedIn() || !in_array($cat, $_layoutPrivateCats, true);
|
||||
},
|
||||
ARRAY_FILTER_USE_KEY
|
||||
) : [];
|
||||
$_layoutCurrentCat = trim($_GET['cat'] ?? '');
|
||||
?>
|
||||
<a class="navbar-brand d-flex flex-column lh-1" href="/">
|
||||
<span><?= htmlspecialchars(siteTitle()) ?></span>
|
||||
<small class="navbar-tagline"><?= htmlspecialchars(siteClaim()) ?></small>
|
||||
@@ -116,7 +116,7 @@
|
||||
<div class="footer-about">
|
||||
<strong><?= htmlspecialchars(siteTitle()) ?></strong>
|
||||
<p><?= htmlspecialchars(siteClaim()) ?></p>
|
||||
<small>© <?= date('Y') ?> — <a href="https://creativecommons.org/licenses/by/4.0/" target="_blank" rel="noopener">CC BY 4.0</a></small>
|
||||
<small>© <?= date('Y') ?> — <a href="<?= htmlspecialchars(siteLicenseUrl()) ?>" target="_blank" rel="noopener"><?= htmlspecialchars(siteLicenseLabel()) ?></a></small>
|
||||
</div>
|
||||
<nav class="footer-nav" aria-label="Liens du site">
|
||||
<a href="/about">À propos</a>
|
||||
|
||||
Reference in New Issue
Block a user