/** * Registers module in the module manager * * @param int $id id of module * @param string $label text that will be displayed in main menu * @param string $class_name class name * @param string $path include path */ public static function registerModule($id, $label, $class_name, $path) { if (func_num_args() > 4 && !UserRights::checkRights(array_slice(func_get_args(), 4))) { return; } ModuleManager::$module_list[$id]['class'] = $class_name; ModuleManager::$module_list[$id]['path'] = $path; ModuleManager::$module_list[$id]['label'] = $label; }