content
* Supports: [id="..."], [class="..."], combined [id="..." class="..."]
*/
if (!function_exists('parseFooterShortcodes')) {
function parseFooterShortcodes($text) {
// [id="value" class="value"]content[/id] or [/class]
return preg_replace_callback(
'/\[([^\]]+)\](.*?)\[\/\w+\]/s',
function ($m) {
$attrs = $m[1];
$content = $m[2];
$htmlAttrs = '';
if (preg_match('/id="([^"]*)"/', $attrs, $id)) {
$htmlAttrs .= ' id="' . htmlspecialchars($id[1]) . '"';
}
if (preg_match('/class="([^"]*)"/', $attrs, $cls)) {
$htmlAttrs .= ' class="' . htmlspecialchars($cls[1]) . '"';
}
return '' . $content . '';
},
$text
);
}
}
$copyrightHtml = parseFooterShortcodes($copyrightRaw);
$_adminAccessBase = ($basePath === '' ? '/admin/' : rtrim($basePath, '/') . '/admin/');
$_adminAccessBaseJson = json_encode($_adminAccessBase, JSON_UNESCAPED_SLASHES);
$_footerLabels = [
'docs' => ['en' => 'Docs', 'de' => 'Dokumentation', 'es' => 'Docs'],
'privacy' => ['en' => 'Privacy', 'de' => 'Datenschutz', 'es' => 'Privacidad'],
'imprint' => ['en' => 'Imprint', 'de' => 'Impressum', 'es' => 'Aviso legal'],
'language' => ['en' => 'Language selection', 'de' => 'Sprachauswahl', 'es' => 'Selección de idioma'],
];
$_footerPageHref = function (string $page) use ($basePath, $currentLang, $PAGE_MAPPING, $defaultLang): string {
if (isset($PAGE_MAPPING[$page][$currentLang])) {
return $basePath . $PAGE_MAPPING[$page][$currentLang];
}
if (isset($PAGE_MAPPING[$page][$defaultLang])) {
return $basePath . $PAGE_MAPPING[$page][$defaultLang];
}
return $basePath . $page;
};
$_footerSummary = [
'en' => 'raiju is a flat-file CMS written in PHP.
Small. Friendly. Open source.',
'de' => 'raiju ist ein Flat-File-CMS in PHP.
Klein. Freundlich. Open Source.',
'es' => 'raiju es un CMS flat-file escrito en PHP.
Pequeño. Amable. Open source.',
];
?>
true,
'rights' => array_combine(RAIJU_AGENT_RIGHTS, array_map('raijuAgentCan', RAIJU_AGENT_RIGHTS)),
'classic' => raijuAgentSettings()['classicMode'] !== false,
'maxUploadFiles' => 6,
'maxUploadBytes' => function_exists('getMediaConfig') ? (int)(getMediaConfig('image')['maxSize'] ?? 10485760) : 10485760,
];
}
}
?>