/** * Init Application * * @return void */ public function init($section = "*DEFAULT*") { if ($this->checkPermission("applications", "effectweb", true)) { global $appsCache; if ($_GET['module'] && !CTM_Dashboard::APP_ModuleExists($_GET['module'])) { return $this->output->setContent("module_failed"); } elseif ($_GET['module']) { $controller = $_GET['module']; } elseif ($section != "*DEFAULT*") { $controller = $section; } else { $controller = $appsCache['effectweb']['section']; } CTM_Dashboard::LoadAPPModule($controller); } }
/** * Init Application * * @return void */ public function init($section = "*DEFAULT*", $load = "app_section.php") { global $appsCache; self::loadSources(); $CTM_EWGeneral = new CTM_EWGeneral(); $EW_Modules = new EW_Modules(); $EW_Modules->loadPublicModules(); $page = $_POST['pag'] ? $_GET['pag'] : $_GET['module']; if ($page && !CTM_Dashboard::APP_ModuleExists($page)) { return $this->output->loadSkinCache("server", "404_error"); } elseif ($_GET['ajax']) { $controller = "Ajax"; } elseif ($page) { $controller = $page; } elseif ($section != "*DEFAULT*") { $controller = $section; } else { $controller = $appsCache['core']['section']; } $CTM_EWGeneral->init(); CTM_Dashboard::LoadAPPModule($controller, $load); }
/** * Private: Start AdminCP * * @return void */ private static function start($core_module = "*DEFAULT*") { self::instance()->lang->loadLanguageFile("global", "Core"); if (!ACP_SESSION_LOGGED) { CTM_Dashboard::LoadAPPModule("global"); } elseif (CTM_BOARD_APP == "Core") { global $appsCache; if ($_GET['ajax']) { $controller = "Ajax"; } elseif ($_GET['module']) { $controller = $_GET['module']; } elseif ($core_module != "*DEFAULT*" && $core_module) { $controller = $core_module; } else { $controller = $appsCache['core']['module']; } CTM_Dashboard::LoadAPPModule($controller); } else { CTM_Dashboard::LoadApplication(CTM_BOARD_APP, ACP_LOAD_MODULE); if (file_exists(THIS_APPLICATION_PATH . "admin/variables/acp_modules_name.php")) { require_once THIS_APPLICATION_PATH . "admin/variables/acp_modules_name.php"; $GLOBALS['acp_modules_name'] = array_merge($GLOBALS['acp_modules_name'], $_acp_modules_name); } } }