24 if($config[
'blocks_enable']){
27 $bks =
RMEvents::get()->run_event(
'rmcommon.retrieve.xoops.blocks', $bks);
28 $b =& $xoopsTpl->get_template_vars(
'xoBlocks');
29 $blocks = array_merge($b, $bks);
30 $xoopsTpl->assign_by_ref(
'xoBlocks',$blocks);
39 if(substr($_SERVER[
'REQUEST_URI'], -10)==
'/admin.php' && strpos($_SERVER[
'REQUEST_URI'],
'modules')===FALSE){
40 header(
'location: '.XOOPS_URL.
'/modules/rmcommon/');
44 if(substr($_SERVER[
'REQUEST_URI'], -16)==
'system/admin.php' && empty($_POST)){
45 header(
'location: '.XOOPS_URL.
'/modules/rmcommon/');
49 require_once XOOPS_ROOT_PATH.
'/modules/rmcommon/loader.php';
59 if($xoopsConfig[
'cpanel']!=
'redmexico'){
60 $db = XoopsDatabaseFactory::getDatabaseConnection();
61 $db->queryF(
"UPDATE ".
$db->prefix(
"config").
" SET conf_value='redmexico' WHERE conf_modid=0 AND conf_catid=1 AND conf_name='cpanel'");
69 if (
$xoopsUser->isAdmin()) $xoopsConfig[
'closesite'] = 0;
72 RMEvents::get()->run_event(
'rmcommon.include.common.language');
90 $blocks =& $params[2];
92 $blocks =
RMEvents::get()->run_event(
'rmcommon.retrieve.xoops.blocks', $blocks, $xpb,
$tpl);
103 RMEvents::get()->run_event(
'rmcommon.redirect.header', $params[0], $params[1], $params[2], $params[3], $params[4]);
104 if(!defined(
'XOOPS_CPFUNC_LOADED'))
return;
117 if(defined(
'RMC_CHECK_UPDATES') && $xoopsOption[
'pagetype']==
'admin'){
120 $rmTpl->add_head_script(
'var xoToken = "'.$xoopsSecurity->createToken().
'";');
129 if(!$xoopsTpl)
return;
131 $xoopsTpl->plugins_dir[] =
RMCPATH.
'/include';
140 $xoopsOption[
'module_subpage'] =
'home-page';
144 $xoopsOption[
'module_subpage'] =
'edit-user';
148 $xoopsOption[
'module_subpage'] =
'readpm';
152 $xoopsOption[
'module_subpage'] =
'register';
156 $xoopsOption[
'module_subpage'] =
'user';
160 $xoopsOption[
'module_subpage'] =
'profile';
164 $xoopsOption[
'module_subpage'] =
'pm';