aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/install
diff options
context:
space:
mode:
authorNathaniel Guse <nathaniel.guse@gmail.com>2013-02-25 13:12:57 -0600
committerNathaniel Guse <nathaniel.guse@gmail.com>2013-02-25 13:12:57 -0600
commite632049e197131df9fbe8c078007cf37cf94c241 (patch)
treef305a7163e264f2ad9eb23c0d224c91b8a848e34 /phpBB/install
parent7a8ae493009eac3d4f5c97279f0be6e10c588002 (diff)
parentf6a894f07700627b675c2b16aab4714df5819a23 (diff)
downloadforums-e632049e197131df9fbe8c078007cf37cf94c241.tar
forums-e632049e197131df9fbe8c078007cf37cf94c241.tar.gz
forums-e632049e197131df9fbe8c078007cf37cf94c241.tar.bz2
forums-e632049e197131df9fbe8c078007cf37cf94c241.tar.xz
forums-e632049e197131df9fbe8c078007cf37cf94c241.zip
Merge branch 'feature/migrations-data' of github.com:EXreaction/phpbb3 into feature/migrations-data
# By Dhruv (19) and others # Via Nathaniel Guse (3) and others * 'feature/migrations-data' of github.com:EXreaction/phpbb3: (38 commits) [feature/migrations] Use the user class for language handling [feature/migrations] Fully revert the removal of the user_msnm field [feature/migrations] Revert unrelated change to schema_data.sql [ticket/11179] remove extra & in function call [ticket/11179] correct start parameter in sphinx search [ticket/11179] correct start parameter in native author search [ticket/11179] correct start parameter in native keyword search [ticket/11179] fix success query path for postgres [ticket/11179] fix success query path for mysql [ticket/11179] minor fixes [ticket/11179] pass start param by reference in postgres [ticket/11179] correct start param in author search of postgres [ticket/11179] correct start parameter in psql keyword search [ticket/11179] pass start param by reference in author search [ticket/11179] correct start parameter for author search [ticket/11179] use FOUND_ROWS query to re-search with changed start param [ticket/11179] pass start parameter by reference [ticket/11179] correct the start parameter while retrieving from cache [ticket/11179] add search query in case initial one fails [ticket/11359] html escape sphinx config data ...
Diffstat (limited to 'phpBB/install')
-rw-r--r--phpBB/install/database_update.php22
-rw-r--r--phpBB/install/install_install.php4
-rw-r--r--phpBB/install/schemas/schema_data.sql1
3 files changed, 13 insertions, 14 deletions
diff --git a/phpBB/install/database_update.php b/phpBB/install/database_update.php
index 459839f393..4938ef0f87 100644
--- a/phpBB/install/database_update.php
+++ b/phpBB/install/database_update.php
@@ -133,9 +133,7 @@ set_config(null, null, null, $config);
set_config_count(null, null, null, $config);
$orig_version = $config['version'];
-include($phpbb_root_path . 'language/' . $config['default_lang'] . '/common.' . $phpEx);
-include($phpbb_root_path . 'language/' . $config['default_lang'] . '/acp/common.' . $phpEx);
-include($phpbb_root_path . 'language/' . $config['default_lang'] . '/install.' . $phpEx);
+$user->add_lang(array('common', 'acp/common', 'install', 'migrator'));
// Add own hook handler, if present. :o
if (file_exists($phpbb_root_path . 'includes/hooks/index.' . $phpEx))
@@ -157,11 +155,11 @@ else
header('Content-type: text/html; charset=UTF-8');
?>
<!DOCTYPE html>
-<html dir="<?php echo $lang['DIRECTION']; ?>" lang="<?php echo $lang['USER_LANG']; ?>">
+<html dir="<?php echo $user->lang['DIRECTION']; ?>" lang="<?php echo $user->lang['USER_LANG']; ?>">
<head>
<meta charset="utf-8">
-<title><?php echo $lang['UPDATING_TO_LATEST_STABLE']; ?></title>
+<title><?php echo $user->lang['UPDATING_TO_LATEST_STABLE']; ?></title>
<link href="<?php echo htmlspecialchars($phpbb_admin_path); ?>style/admin.css" rel="stylesheet" type="text/css" media="screen" />
@@ -178,12 +176,12 @@ header('Content-type: text/html; charset=UTF-8');
<div id="content">
<div id="main" class="install-body">
- <h1><?php echo $lang['UPDATING_TO_LATEST_STABLE']; ?></h1>
+ <h1><?php echo $user->lang['UPDATING_TO_LATEST_STABLE']; ?></h1>
<br />
- <p><?php echo $lang['DATABASE_TYPE']; ?> :: <strong><?php echo $db->sql_layer; ?></strong><br />
- <?php echo $lang['PREVIOUS_VERSION']; ?> :: <strong><?php echo $config['version']; ?></strong><br />
+ <p><?php echo $user->lang['DATABASE_TYPE']; ?> :: <strong><?php echo $db->sql_layer; ?></strong><br />
+ <?php echo $user->lang['PREVIOUS_VERSION']; ?> :: <strong><?php echo $config['version']; ?></strong><br />
<?php
@@ -225,7 +223,7 @@ while (!$migrator->finished())
}
catch (phpbb_db_migration_exception $e)
{
- echo $e;
+ echo $e->getLocalisedMessage($user);
phpbb_end_update($cache);
}
@@ -236,8 +234,8 @@ while (!$migrator->finished())
if ((time() - $update_start_time) >= $safe_time_limit)
{
//echo '<meta http-equiv="refresh" content="0;url=' . str_replace('&', '&amp;', append_sid($phpbb_root_path . 'test.' . $phpEx)) . '" />';
- echo $lang['DATABASE_UPDATE_NOT_COMPLETED'] . '<br />';
- echo '<a href="' . append_sid($phpbb_root_path . 'test.' . $phpEx) . '">' . $lang['DATABASE_UPDATE_CONTINUE'] . '</a>';
+ echo $user->lang['DATABASE_UPDATE_NOT_COMPLETED'] . '<br />';
+ echo '<a href="' . append_sid($phpbb_root_path . 'test.' . $phpEx) . '">' . $user->lang['DATABASE_UPDATE_CONTINUE'] . '</a>';
phpbb_end_update($cache);
}
@@ -248,6 +246,6 @@ if ($orig_version != $config['version'])
add_log('admin', 'LOG_UPDATE_DATABASE', $orig_version, $config['version']);
}
-echo $lang['DATABASE_UPDATE_COMPLETE'];
+echo $user->lang['DATABASE_UPDATE_COMPLETE'];
phpbb_end_update($cache);
diff --git a/phpBB/install/install_install.php b/phpBB/install/install_install.php
index a99de9bec9..67649e6b0f 100644
--- a/phpBB/install/install_install.php
+++ b/phpBB/install/install_install.php
@@ -1457,12 +1457,12 @@ class install_install extends module
*/
function add_modules($mode, $sub)
{
- global $db, $lang, $phpbb_root_path, $phpEx, $phpbb_extension_manager, $config;
+ global $db, $lang, $phpbb_root_path, $phpEx, $phpbb_extension_manager, $config, $phpbb_container;
// modules require an extension manager
if (empty($phpbb_extension_manager))
{
- $phpbb_extension_manager = new phpbb_extension_manager($db, $config, EXT_TABLE, $phpbb_root_path, ".$phpEx");
+ $phpbb_extension_manager = $phpbb_container->get('ext.manager');
}
include_once($phpbb_root_path . 'includes/acp/acp_modules.' . $phpEx);
diff --git a/phpBB/install/schemas/schema_data.sql b/phpBB/install/schemas/schema_data.sql
index 4e4d70ced3..7c1a7d40f5 100644
--- a/phpBB/install/schemas/schema_data.sql
+++ b/phpBB/install/schemas/schema_data.sql
@@ -611,6 +611,7 @@ INSERT INTO phpbb_acl_groups (group_id, forum_id, auth_option_id, auth_role_id,
# NEW MEMBERS on the queue
INSERT INTO phpbb_acl_groups (group_id, forum_id, auth_option_id, auth_role_id, auth_setting) VALUES (7, 2, 0, 24, 0);
+
# -- Demo Topic
INSERT INTO phpbb_topics (topic_title, topic_poster, topic_time, topic_views, topic_replies, topic_replies_real, forum_id, topic_status, topic_type, topic_first_post_id, topic_first_poster_name, topic_first_poster_colour, topic_last_post_id, topic_last_poster_id, topic_last_poster_name, topic_last_poster_colour, topic_last_post_subject, topic_last_post_time, topic_last_view_time, poll_title) VALUES ('{L_TOPICS_TOPIC_TITLE}', 2, 972086460, 0, 0, 0, 2, 0, 0, 1, 'Admin', 'AA0000', 1, 2, 'Admin', 'AA0000', '{L_TOPICS_TOPIC_TITLE}', 972086460, 972086460, '');