XoopsModules25x /
lexikon
| 1 | <?php |
||
| 2 | /** |
||
| 3 | * Module: Lexikon |
||
| 4 | * Author: Yerres |
||
| 5 | * Licence: GNU |
||
| 6 | */ |
||
| 7 | |||
| 8 | use XoopsModules\Lexikon\{ |
||
| 9 | Helper, |
||
| 10 | Utility |
||
| 11 | }; |
||
| 12 | /** @var Helper $helper */ |
||
| 13 | |||
| 14 | $GLOBALS['xoopsOption']['template_main'] = 'lx_content.tpl'; |
||
| 15 | require __DIR__ . '/header.php'; |
||
| 16 | require XOOPS_ROOT_PATH . '/header.php'; |
||
| 17 | |||
| 18 | |||
| 19 | $helper = Helper::getInstance(); |
||
| 20 | |||
| 21 | global $xoTheme, $xoopsUser; |
||
| 22 | $myts = \MyTextSanitizer::getInstance(); |
||
| 23 | if (!is_object($xoopsUser) && 0 === $helper->getConfig('contentsyndication')) { |
||
| 24 | redirect_header(XOOPS_URL . '/user.php?xoops_redirect=' . parse_url($_SERVER['SCRIPT_NAME']), 5, _NOPERM); |
||
|
0 ignored issues
–
show
Bug
introduced
by
Loading history...
|
|||
| 25 | } |
||
| 26 | |||
| 27 | require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php'; |
||
| 28 | |||
| 29 | require __DIR__ . '/include/syndication.inc.php'; |
||
| 30 | $yform->assign($xoopsTpl); |
||
| 31 | |||
| 32 | // Various strings |
||
| 33 | $xoopsTpl->assign('introcontentsyn', sprintf(_MD_LEXIKON_INTROCONTENTSYN, $xoopsConfig['sitename'])); |
||
| 34 | $xoopsTpl->assign('modulename', $xoopsModule->dirname()); |
||
| 35 | $xoopsTpl->assign('lang_modulename', $xoopsModule->name()); |
||
| 36 | $xoopsTpl->assign('lang_moduledirname', $xoopsModule->getVar('dirname')); |
||
| 37 | |||
| 38 | $xoopsTpl->assign('xoops_pagetitle', _MD_LEXIKON_SYNDICATION . ' - ' . htmlspecialchars($xoopsModule->name(), ENT_QUOTES | ENT_HTML5)); |
||
| 39 | $xoopsTpl->assign('xoops_module_header', '<link rel="stylesheet" type="text/css" href="assets/css/style.css" >'); |
||
| 40 | |||
| 41 | // Meta data |
||
| 42 | $meta_description = _MD_LEXIKON_SYNDICATION . ' - ' . htmlspecialchars($xoopsModule->name(), ENT_QUOTES | ENT_HTML5); |
||
| 43 | if (isset($xoTheme) && is_object($xoTheme)) { |
||
| 44 | $xoTheme->addMeta('meta', 'description', $meta_description); |
||
| 45 | } else { |
||
| 46 | $xoopsTpl->assign('xoops_meta_description', $meta_description); |
||
| 47 | } |
||
| 48 | |||
| 49 | require XOOPS_ROOT_PATH . '/footer.php'; |
||
| 50 |