/** * Initialize the autoloader, and register its autoload method * @return void */ public static function setup() { if (!self::$initialized) { self::register(dirname(dirname(__FILE__))); spl_autoload_register(array('icms_Autoloader', 'autoload')); spl_autoload_register(array('icms_Autoloader', 'registerLegacy')); self::$initialized = TRUE; } }
/** * register class path with autoloader * notice: this function may not be used for the system module * * @param bool $isactive if TRUE, the class path is only registered if the module is active * if FALSE, the class path is only registered if the module is inactive * @return void */ public function registerClassPath($isactive = NULL) { if ($this->getVar("dirname") == "system") { return; } $class_path = ICMS_ROOT_PATH . "/modules/" . $this->getVar("dirname") . "/class"; // check if class path exists if (!is_dir($class_path)) { return; } // check if module is active (only if applicable) if ($isactive !== NULL && $this->getVar("isactive") != (int) $isactive) { return; } // register class path if ($this->getVar("ipf")) { $modname = $this->getVar("modname") != "" ? $this->getVar("modname") : $this->getVar("dirname"); icms_Autoloader::register($class_path, "mod_" . $modname); } else { icms_Autoloader::register($class_path); } }
date_default_timezone_set("UTC"); } /** * If non-empty, only this user can access this installer */ define('INSTALL_USER', ''); define('INSTALL_PASSWORD', ''); // options for mainfile.php $xoopsOption['nocommon'] = true; define('XOOPS_INSTALL', 1); include '../mainfile.php'; include_once '../include/version.php'; // including a few functions require_once 'include/functions.php'; require_once '../libraries/icms/Autoloader.php'; icms_Autoloader::setup(); error_reporting(E_ALL); class XoopsInstallWizard { var $pages = array(); var $titles = array(); var $currentPage = 0; var $lastpage; var $secondlastpage; var $language = 'english'; var $no_php5 = false; var $safe_mode = false; function xoInit() { if (!$this->checkAccess()) { return false;
/** * Initialize ImpressCMS before bootstrap */ public static function setup() { self::$paths['www'] = array(ICMS_ROOT_PATH, ICMS_URL); self::$paths['modules'] = array(ICMS_ROOT_PATH . '/modules', ICMS_URL . '/modules'); self::$paths['themes'] = array(ICMS_THEME_PATH, ICMS_THEME_URL); self::buildRelevantUrls(); // Initialize the autoloader require_once dirname(__FILE__) . '/icms/Autoloader.php'; icms_Autoloader::setup(); register_shutdown_function(array(__CLASS__, 'shutdown')); }