aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/install
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/install')
-rw-r--r--phpBB/install/database_update.php10
-rw-r--r--phpBB/install/index.php21
-rw-r--r--phpBB/install/install_convert.php8
-rw-r--r--phpBB/install/install_install.php14
-rw-r--r--phpBB/install/install_update.php6
5 files changed, 34 insertions, 25 deletions
diff --git a/phpBB/install/database_update.php b/phpBB/install/database_update.php
index 3be5ea659c..fa8ec6b6ce 100644
--- a/phpBB/install/database_update.php
+++ b/phpBB/install/database_update.php
@@ -77,16 +77,16 @@ require($phpbb_root_path . 'includes/utf/utf_tools.' . $phpEx);
set_error_handler(defined('PHPBB_MSG_HANDLER') ? PHPBB_MSG_HANDLER : 'msg_handler');
// Setup class loader first
-$phpbb_class_loader = new phpbb_class_loader('phpbb_', "{$phpbb_root_path}phpbb/", $phpEx);
+$phpbb_class_loader = new \phpbb\class_loader('phpbb\\', "{$phpbb_root_path}phpbb/", $phpEx);
$phpbb_class_loader->register();
// Set up container (must be done here because extensions table may not exist)
$container_extensions = array(
- new phpbb_di_extension_config($phpbb_root_path . 'config.' . $phpEx),
- new phpbb_di_extension_core($phpbb_root_path . 'config/'),
+ new \phpbb\di\extension\config($phpbb_root_path . 'config.' . $phpEx),
+ new \phpbb\di\extension\core($phpbb_root_path . 'config/'),
);
$container_passes = array(
- new phpbb_di_pass_collection_pass(),
+ new \phpbb\di\pass\collection_pass(),
);
$phpbb_container = phpbb_create_container($container_extensions, $phpbb_root_path, $phpEx);
@@ -211,7 +211,7 @@ while (!$migrator->finished())
{
$migrator->update();
}
- catch (phpbb_db_migration_exception $e)
+ catch (\phpbb\db\migration\exception $e)
{
echo $e->getLocalisedMessage($user);
diff --git a/phpBB/install/index.php b/phpBB/install/index.php
index ec9aa5f32a..90d840aa31 100644
--- a/phpBB/install/index.php
+++ b/phpBB/install/index.php
@@ -108,11 +108,11 @@ phpbb_include_updated('includes/utf/utf_tools.' . $phpEx);
phpbb_require_updated('includes/functions_install.' . $phpEx);
// Setup class loader first
-$phpbb_class_loader_new = new phpbb_class_loader('phpbb_', "{$phpbb_root_path}install/update/new/phpbb/", $phpEx);
+$phpbb_class_loader_new = new \phpbb\class_loader('phpbb_', "{$phpbb_root_path}install/update/new/phpbb/", $phpEx);
$phpbb_class_loader_new->register();
-$phpbb_class_loader = new phpbb_class_loader('phpbb_', "{$phpbb_root_path}phpbb/", $phpEx);
+$phpbb_class_loader = new \phpbb\class_loader('phpbb_', "{$phpbb_root_path}phpbb/", $phpEx);
$phpbb_class_loader->register();
-$phpbb_class_loader_ext = new phpbb_class_loader('phpbb_ext_', "{$phpbb_root_path}ext/", $phpEx);
+$phpbb_class_loader_ext = new \phpbb\class_loader('phpbb_ext_', "{$phpbb_root_path}ext/", $phpEx);
$phpbb_class_loader_ext->register();
// Set up container
@@ -219,8 +219,8 @@ $sub = $request->variable('sub', '');
// Set PHP error handler to ours
set_error_handler(defined('PHPBB_MSG_HANDLER') ? PHPBB_MSG_HANDLER : 'msg_handler');
-$user = new phpbb_user();
-$auth = new phpbb_auth();
+$user = new \phpbb\user();
+$auth = new \phpbb\auth\auth();
// Add own hook handler, if present. :o
if (file_exists($phpbb_root_path . 'includes/hooks/index.' . $phpEx))
@@ -240,15 +240,24 @@ else
}
// Set some standard variables we want to force
-$config = new phpbb_config(array(
+$config = new \phpbb\config\config(array(
'load_tplcompile' => '1'
));
+<<<<<<< HEAD
+$phpbb_style_resource_locator = new \phpbb\style\resource_locator();
+$phpbb_style_path_provider = new \phpbb\style\path_provider();
+$template = new \phpbb\template\twig\twig($phpbb_root_path, $phpEx, $config, $user, new \phpbb\template\context());
+$phpbb_style = new \phpbb\style\style($phpbb_root_path, $phpEx, $config, $user, $phpbb_style_resource_locator, $phpbb_style_path_provider, $template);
+$phpbb_style->set_ext_dir_prefix('adm/');
+$phpbb_style->set_custom_style('admin', $phpbb_admin_path . 'style', array(), '');
+=======
$template = new phpbb_template_twig($phpbb_root_path, $phpEx, $config, $user, new phpbb_template_context());
$paths = array($phpbb_root_path . 'install/update/new/adm/style', $phpbb_admin_path . 'style');
$paths = array_filter($paths, 'is_dir');
$template->set_custom_style('adm', $paths);
+>>>>>>> github-phpbb/develop
$template->assign_var('T_ASSETS_PATH', '../assets');
$template->assign_var('T_TEMPLATE_PATH', $phpbb_admin_path . 'style');
diff --git a/phpBB/install/install_convert.php b/phpBB/install/install_convert.php
index 8a8c440036..4d3e1d3d4a 100644
--- a/phpBB/install/install_convert.php
+++ b/phpBB/install/install_convert.php
@@ -130,7 +130,7 @@ class install_convert extends module
unset($dbpasswd);
// We need to fill the config to let internal functions correctly work
- $config = new phpbb_config_db($db, new phpbb_cache_driver_null, CONFIG_TABLE);
+ $config = new \phpbb\config\db($db, new \phpbb\cache\driver\null, CONFIG_TABLE);
set_config(null, null, null, $config);
set_config_count(null, null, null, $config);
@@ -345,7 +345,7 @@ class install_convert extends module
$this->page_title = $lang['STAGE_SETTINGS'];
// We need to fill the config to let internal functions correctly work
- $config = new phpbb_config_db($db, new phpbb_cache_driver_null, CONFIG_TABLE);
+ $config = new \phpbb\config\db($db, new \phpbb\cache\driver\null, CONFIG_TABLE);
set_config(null, null, null, $config);
set_config_count(null, null, null, $config);
@@ -586,7 +586,7 @@ class install_convert extends module
unset($dbpasswd);
// We need to fill the config to let internal functions correctly work
- $config = new phpbb_config_db($db, new phpbb_cache_driver_null, CONFIG_TABLE);
+ $config = new \phpbb\config\db($db, new \phpbb\cache\driver\null, CONFIG_TABLE);
set_config(null, null, null, $config);
set_config_count(null, null, null, $config);
@@ -739,7 +739,7 @@ class install_convert extends module
// For conversions we are a bit less strict and set to a search backend we know exist...
if (!class_exists($search_type))
{
- $search_type = 'phpbb_search_fulltext_native';
+ $search_type = '\phpbb\search\fulltext_native';
set_config('search_type', $search_type);
}
diff --git a/phpBB/install/install_install.php b/phpBB/install/install_install.php
index ea23c318e3..107da0f90a 100644
--- a/phpBB/install/install_install.php
+++ b/phpBB/install/install_install.php
@@ -102,7 +102,7 @@ class install_install extends module
break;
case 'final':
- // Enable super globals to prevent issues with the new phpbb_request object
+ // Enable super globals to prevent issues with the new \phpbb\request\request object
$request->enable_super_globals();
// Create a normal container now
@@ -1438,12 +1438,12 @@ class install_install extends module
include_once($phpbb_root_path . 'phpbb/search/fulltext_native.' . $phpEx);
// We need to fill the config to let internal functions correctly work
- $config = new phpbb_config_db($db, new phpbb_cache_driver_null, CONFIG_TABLE);
+ $config = new \phpbb\config\db($db, new \phpbb\cache\driver\null, CONFIG_TABLE);
set_config(null, null, null, $config);
set_config_count(null, null, null, $config);
$error = false;
- $search = new phpbb_search_fulltext_native($error, $phpbb_root_path, $phpEx, $auth, $config, $db, $user);
+ $search = new \phpbb\search\fulltext_native($error, $phpbb_root_path, $phpEx, $auth, $config, $db, $user);
$sql = 'SELECT post_id, post_subject, post_text, poster_id, forum_id
FROM ' . POSTS_TABLE;
@@ -1753,7 +1753,7 @@ class install_install extends module
$data = $this->get_submitted_data();
// We need to fill the config to let internal functions correctly work
- $config = new phpbb_config_db($db, new phpbb_cache_driver_null, CONFIG_TABLE);
+ $config = new \phpbb\config\db($db, new \phpbb\cache\driver\null, CONFIG_TABLE);
set_config(null, null, null, $config);
set_config_count(null, null, null, $config);
@@ -1827,7 +1827,7 @@ class install_install extends module
$data = $this->get_submitted_data();
// We need to fill the config to let internal functions correctly work
- $config = new phpbb_config_db($db, new phpbb_cache_driver_null, CONFIG_TABLE);
+ $config = new \phpbb\config\db($db, new \phpbb\cache\driver\null, CONFIG_TABLE);
set_config(null, null, null, $config);
set_config_count(null, null, null, $config);
@@ -1892,8 +1892,8 @@ class install_install extends module
* "installs" means it adds all migrations to the migrations table, but does not
* perform any of the actions in the migrations.
*
- * @param phpbb_extension_manager $extension_manager
- * @param phpbb_db_migrator $migrator
+ * @param \phpbb\extension\manager $extension_manager
+ * @param \phpbb\db\migrator $migrator
*/
function populate_migrations($extension_manager, $migrator)
{
diff --git a/phpBB/install/install_update.php b/phpBB/install/install_update.php
index 8ab0ad49d3..b7b358ab2f 100644
--- a/phpBB/install/install_update.php
+++ b/phpBB/install/install_update.php
@@ -111,7 +111,7 @@ class install_update extends module
unset($dbpasswd);
// We need to fill the config to let internal functions correctly work
- $config = new phpbb_config_db($db, new phpbb_cache_driver_null, CONFIG_TABLE);
+ $config = new \phpbb\config\db($db, new \phpbb\cache\driver\null, CONFIG_TABLE);
set_config(null, null, null, $config);
set_config_count(null, null, null, $config);
@@ -250,7 +250,7 @@ class install_update extends module
$this->include_file('includes/diff/renderer.' . $phpEx);
// Make sure we stay at the file check if checking the files again
- if ($request->variable('check_again', false, false, phpbb_request_interface::POST))
+ if ($request->variable('check_again', false, false, \phpbb\request\request_interface::POST))
{
$sub = $this->p_master->sub = 'file_check';
}
@@ -338,7 +338,7 @@ class install_update extends module
$action = request_var('action', '');
// We are directly within an update. To make sure our update list is correct we check its status.
- $update_list = ($request->variable('check_again', false, false, phpbb_request_interface::POST)) ? false : $cache->get('_update_list');
+ $update_list = ($request->variable('check_again', false, false, \phpbb\request\request_interface::POST)) ? false : $cache->get('_update_list');
$modified = ($update_list !== false) ? @filemtime($cache->get_driver()->cache_dir . 'data_update_list.' . $phpEx) : 0;
// Make sure the list is up-to-date