admin/admin_header.php
<?php
/**
* MyLinks module
*
* You may not change or alter any portion of this comment or credits
* of supporting developers from this source code or any supporting source code
* which is considered copyrighted (c) material of the original comment or credit authors.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
*
* @copyright :: {@link http://xoops.org/ XOOPS Project}
* @license :: {@link http://www.gnu.org/licenses/gpl-2.0.html GNU Public License}
* @package :: mylinks
* @subpackage:: admin
*/
$path = dirname(dirname(dirname(__DIR__)));
include_once $path . '/mainfile.php';
include_once $path . '/include/cp_functions.php';
require_once $path . '/include/cp_header.php';
global $xoopsModule;
$thisModuleDir = $GLOBALS['xoopsModule']->getVar('dirname');
$thisModulePath = dirname(__DIR__);
// Load language files
xoops_loadLanguage('admin', $thisModuleDir);
xoops_loadLanguage('modinfo', $thisModuleDir);
xoops_loadLanguage('main', $thisModuleDir);
$pathIcon16 = '../' . $xoopsModule->getInfo('icons16');
$pathIcon32 = '../' . $xoopsModule->getInfo('icons32');
$pathModuleAdmin = $xoopsModule->getInfo('dirmoduleadmin');
if (file_exists($GLOBALS['xoops']->path($pathModuleAdmin . '/moduleadmin.php'))) {
include_once $GLOBALS['xoops']->path($pathModuleAdmin . '/moduleadmin.php');
} else {
redirect_header('../../../admin.php', 5, _AM_MODULEADMIN_MISSING, false);
}