diff options
Diffstat (limited to 'phpBB/install/index.php')
-rw-r--r-- | phpBB/install/index.php | 23 |
1 files changed, 16 insertions, 7 deletions
diff --git a/phpBB/install/index.php b/phpBB/install/index.php index 49c99da0d7..3cbc8744dd 100644 --- a/phpBB/install/index.php +++ b/phpBB/install/index.php @@ -152,6 +152,7 @@ else @ini_set('memory_limit', $mem_limit); // Include essential scripts +require($phpbb_root_path . 'includes/class_loader.' . $phpEx); require($phpbb_root_path . 'includes/functions.' . $phpEx); if (file_exists($phpbb_root_path . 'includes/functions_content.' . $phpEx)) @@ -162,12 +163,23 @@ if (file_exists($phpbb_root_path . 'includes/functions_content.' . $phpEx)) include($phpbb_root_path . 'includes/auth.' . $phpEx); include($phpbb_root_path . 'includes/session.' . $phpEx); include($phpbb_root_path . 'includes/template.' . $phpEx); -include($phpbb_root_path . 'includes/acm/acm_file.' . $phpEx); -include($phpbb_root_path . 'includes/cache.' . $phpEx); include($phpbb_root_path . 'includes/functions_admin.' . $phpEx); include($phpbb_root_path . 'includes/utf/utf_tools.' . $phpEx); require($phpbb_root_path . 'includes/functions_install.' . $phpEx); +$class_loader = new phpbb_class_loader($phpbb_root_path, '.' . $phpEx); +$class_loader->register(); + +// set up caching +$cache_factory = new phpbb_cache_factory('file'); +$cache = $cache_factory->get_service(); +$class_loader->set_cache($cache->get_driver()); + +$request = new phpbb_request(); + +// make sure request_var uses this request instance +request_var('', 0, false, false, $request); // "dependency injection" for a function + // Try and load an appropriate language if required $language = basename(request_var('language', '')); @@ -250,7 +262,6 @@ set_error_handler(defined('PHPBB_MSG_HANDLER') ? PHPBB_MSG_HANDLER : 'msg_handle $user = new user(); $auth = new auth(); -$cache = new cache(); $template = new template(); // Add own hook handler, if present. :o @@ -270,9 +281,9 @@ else } // Set some standard variables we want to force -$config = array( +$config = new phpbb_config(array( 'load_tplcompile' => '1' -); +)); $template->set_custom_template('../adm/style', 'admin'); $template->assign_var('T_TEMPLATE_PATH', '../adm/style'); @@ -808,5 +819,3 @@ class module return $user_select; } } - -?>
\ No newline at end of file |