1
I am developing my next version (1.6) of Video Tube module and have hit a roadblock I can't figure out. I don't seem to be able to access the $xoopsModuleConfig global in admin/index.php file.
le="color: #000000"><?php //admin/index.php excerpt include_once("admin_header.php"); global $xoopsOption, $xoopsDB, $xoopsUser, $xoopsConfig, $xoopsModuleConfig; $vusecats = $xoopsModuleConfig['videousecats']; if ($vusecats) { $numcolumns = 9; }else{ $numcolumns = 8; }
$vusecats returns a '0' but it should be '1'. xoopsModuleConfig['videousecats'] is working in all of my other files, just not in the admin/index.php file.
le="color: #000000"><?php //admin/adminheader.php excerpt include_once '../../../mainfile.php'; include_once XOOPS_ROOT_PATH."/header.php"; include_once XOOPS_ROOT_PATH."/class/xoopsmodule.php"; include_once XOOPS_ROOT_PATH."/include/cp_functions.php"; if ($xoopsUser) { $xoopsModule = XoopsModule::getByDirname("videotube"); if ( !$xoopsUser->isAdmin($xoopsModule->mid()) ) { redirect_header(XOOPS_URL."/",3,_NOPERM);; exit(); } } else { redirect_header(XOOPS_URL."/",3,_NOPERM); exit(); }
I know I must be overlooking something.
I am working with XOOPS 2.0.16
le="color: #000000"><?php //snippets from xoops_version.php // Admin things $modversion['hasAdmin'] = 1; $modversion['adminindex'] = "admin/index.php"; $modversion['adminmenu'] = "admin/menu.php"; $modversion['config'][13]['name'] = 'videousecats'; $modversion['config'][13]['title'] = '_MI_VP_VCATEGORIESENABLE'; $modversion['config'][13]['description'] = '_MI_VP_VCATEGORIESENABLEDSC'; $modversion['config'][13]['formtype'] = 'yesno'; $modversion['config'][13]['valuetype'] = 'int'; $modversion['config'][13]['default'] = 0;
Any suggestions?