aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/install
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/install')
-rw-r--r--phpBB/install/convertors/convert_phpbb20.php2
-rw-r--r--phpBB/install/convertors/functions_phpbb20.php3
-rw-r--r--phpBB/install/database_update.php10
-rw-r--r--phpBB/install/install_convert.php3
-rw-r--r--phpBB/install/install_install.php48
-rw-r--r--phpBB/install/schemas/schema_data.sql4
6 files changed, 60 insertions, 10 deletions
diff --git a/phpBB/install/convertors/convert_phpbb20.php b/phpBB/install/convertors/convert_phpbb20.php
index 926f139da4..5f672ca092 100644
--- a/phpBB/install/convertors/convert_phpbb20.php
+++ b/phpBB/install/convertors/convert_phpbb20.php
@@ -33,7 +33,7 @@ $dbms = phpbb_convert_30_dbms_to_31($dbms);
$convertor_data = array(
'forum_name' => 'phpBB 2.0.x',
'version' => '1.0.3',
- 'phpbb_version' => '3.1.0-b2',
+ 'phpbb_version' => '3.1.0-b3',
'author' => '<a href="https://www.phpbb.com/">phpBB Group</a>',
'dbms' => $dbms,
'dbhost' => $dbhost,
diff --git a/phpBB/install/convertors/functions_phpbb20.php b/phpBB/install/convertors/functions_phpbb20.php
index 29e5f7ab09..b5a69abe93 100644
--- a/phpBB/install/convertors/functions_phpbb20.php
+++ b/phpBB/install/convertors/functions_phpbb20.php
@@ -71,7 +71,6 @@ function phpbb_insert_forums()
$prune_enabled = (int) $src_db->sql_fetchfield('config_value');
$src_db->sql_freeresult($result);
-
// Insert categories
$sql = 'SELECT cat_id, cat_title
FROM ' . $convert->src_table_prefix . 'categories
@@ -571,7 +570,6 @@ function phpbb_convert_authentication($mode)
// What we will do is handling all 2.0.x admins as founder to replicate what is common in 2.0.x.
// After conversion the main admin need to make sure he is removing permissions and the founder status if wanted.
-
// Grab user ids of users with user_level of ADMIN
$sql = "SELECT user_id
FROM {$convert->src_table_prefix}users
@@ -1845,6 +1843,7 @@ function phpbb_create_userconv_table()
break;
case 'sqlite':
+ case 'sqlite3':
$create_sql = 'CREATE TABLE ' . USERCONV_TABLE . ' (
user_id INTEGER NOT NULL DEFAULT \'0\',
username_clean varchar(255) NOT NULL DEFAULT \'\'
diff --git a/phpBB/install/database_update.php b/phpBB/install/database_update.php
index 6c9eeb6a75..b1bfbc1839 100644
--- a/phpBB/install/database_update.php
+++ b/phpBB/install/database_update.php
@@ -115,7 +115,13 @@ request_var('', 0, false, false, $request); // "dependency injection" for a func
$config = $phpbb_container->get('config');
set_config(null, null, null, $config);
set_config_count(null, null, null, $config);
-$orig_version = $config['version'];
+
+if (!isset($config['version_update_from']))
+{
+ $config->set('version_update_from', $config['version']);
+}
+
+$orig_version = $config['version_update_from'];
$user->add_lang(array('common', 'acp/common', 'install', 'migrator'));
@@ -287,4 +293,6 @@ else
echo $user->lang['COMPLETE_LOGIN_TO_BOARD'];
}
+$config->delete('version_update_from');
+
phpbb_end_update($cache, $config);
diff --git a/phpBB/install/install_convert.php b/phpBB/install/install_convert.php
index 82311bd04d..13001426f7 100644
--- a/phpBB/install/install_convert.php
+++ b/phpBB/install/install_convert.php
@@ -249,6 +249,7 @@ class install_convert extends module
switch ($db->sql_layer)
{
case 'sqlite':
+ case 'sqlite3':
case 'firebird':
$db->sql_query('DELETE FROM ' . SESSIONS_KEYS_TABLE);
$db->sql_query('DELETE FROM ' . SESSIONS_TABLE);
@@ -696,6 +697,7 @@ class install_convert extends module
switch ($src_db->sql_layer)
{
case 'sqlite':
+ case 'sqlite3':
case 'firebird':
$convert->src_truncate_statement = 'DELETE FROM ';
break;
@@ -728,6 +730,7 @@ class install_convert extends module
switch ($db->sql_layer)
{
case 'sqlite':
+ case 'sqlite3':
case 'firebird':
$convert->truncate_statement = 'DELETE FROM ';
break;
diff --git a/phpBB/install/install_install.php b/phpBB/install/install_install.php
index dcf2756850..f9d5edc903 100644
--- a/phpBB/install/install_install.php
+++ b/phpBB/install/install_install.php
@@ -217,7 +217,6 @@ class install_install extends module
'S_LEGEND' => false,
));
-
// Check for getimagesize
if (@function_exists('getimagesize'))
{
@@ -291,8 +290,8 @@ class install_install extends module
$checks = array(
array('func_overload', '&', MB_OVERLOAD_MAIL|MB_OVERLOAD_STRING),
array('encoding_translation', '!=', 0),
- array('http_input', '!=', 'pass'),
- array('http_output', '!=', 'pass')
+ array('http_input', '!=', array('pass', '')),
+ array('http_output', '!=', array('pass', ''))
);
foreach ($checks as $mb_checks)
@@ -313,7 +312,8 @@ class install_install extends module
break;
case '!=':
- if ($ini_val != $mb_checks[2])
+ if (!is_array($mb_checks[2]) && $ini_val != $mb_checks[2] ||
+ is_array($mb_checks[2]) && !in_array($ini_val, $mb_checks[2]))
{
$result = '<strong style="color:red">' . $lang['NO'] . '</strong>';
$passed['mbstring'] = false;
@@ -535,7 +535,6 @@ class install_install extends module
$url = (!in_array(false, $passed)) ? $this->p_master->module_url . "?mode=$mode&amp;sub=database&amp;language=$language" : $this->p_master->module_url . "?mode=$mode&amp;sub=requirements&amp;language=$language ";
$submit = (!in_array(false, $passed)) ? $lang['INSTALL_START'] : $lang['INSTALL_TEST'];
-
$template->assign_vars(array(
'L_SUBMIT' => $submit,
'S_HIDDEN' => $s_hidden_fields,
@@ -1649,6 +1648,45 @@ class install_install extends module
$_module->move_module_by($row, 'move_up', 5);
}
+ if ($module_class == 'mcp')
+ {
+ // Move pm report details module 3 down...
+ $sql = 'SELECT *
+ FROM ' . MODULES_TABLE . "
+ WHERE module_basename = 'mcp_pm_reports'
+ AND module_class = 'mcp'
+ AND module_mode = 'pm_report_details'";
+ $result = $db->sql_query($sql);
+ $row = $db->sql_fetchrow($result);
+ $db->sql_freeresult($result);
+
+ $_module->move_module_by($row, 'move_down', 3);
+
+ // Move closed pm reports module 3 down...
+ $sql = 'SELECT *
+ FROM ' . MODULES_TABLE . "
+ WHERE module_basename = 'mcp_pm_reports'
+ AND module_class = 'mcp'
+ AND module_mode = 'pm_reports_closed'";
+ $result = $db->sql_query($sql);
+ $row = $db->sql_fetchrow($result);
+ $db->sql_freeresult($result);
+
+ $_module->move_module_by($row, 'move_down', 3);
+
+ // Move open pm reports module 3 down...
+ $sql = 'SELECT *
+ FROM ' . MODULES_TABLE . "
+ WHERE module_basename = 'mcp_pm_reports'
+ AND module_class = 'mcp'
+ AND module_mode = 'pm_reports'";
+ $result = $db->sql_query($sql);
+ $row = $db->sql_fetchrow($result);
+ $db->sql_freeresult($result);
+
+ $_module->move_module_by($row, 'move_down', 3);
+ }
+
if ($module_class == 'ucp')
{
// Move attachment module 4 down...
diff --git a/phpBB/install/schemas/schema_data.sql b/phpBB/install/schemas/schema_data.sql
index bc76bf55b9..0f9976a96b 100644
--- a/phpBB/install/schemas/schema_data.sql
+++ b/phpBB/install/schemas/schema_data.sql
@@ -21,6 +21,7 @@ INSERT INTO phpbb_config (config_name, config_value) VALUES ('allow_cdn', '0');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('allow_emailreuse', '0');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('allow_password_reset', '1');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('allow_forum_notify', '1');
+INSERT INTO phpbb_config (config_name, config_value) VALUES ('allow_live_searches', '1');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('allow_mass_pm', '1');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('allow_name_chars', 'USERNAME_CHARS_ANY');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('allow_namechange', '0');
@@ -56,6 +57,7 @@ INSERT INTO phpbb_config (config_name, config_value) VALUES ('avatar_min_width',
INSERT INTO phpbb_config (config_name, config_value) VALUES ('avatar_path', 'images/avatars/upload');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('avatar_salt', 'phpbb_avatar');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('board_contact', 'contact@yourdomain.tld');
+INSERT INTO phpbb_config (config_name, config_value) VALUES ('board_contact_name', '');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('board_disable', '0');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('board_disable_msg', '');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('board_email', 'address@yourdomain.tld');
@@ -269,7 +271,7 @@ INSERT INTO phpbb_config (config_name, config_value) VALUES ('tpl_allow_php', '0
INSERT INTO phpbb_config (config_name, config_value) VALUES ('upload_icons_path', 'images/upload_icons');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('upload_path', 'files');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('use_system_cron', '0');
-INSERT INTO phpbb_config (config_name, config_value) VALUES ('version', '3.1.0-b3-dev');
+INSERT INTO phpbb_config (config_name, config_value) VALUES ('version', '3.1.0-b4-dev');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('warnings_expire_days', '90');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('warnings_gc', '14400');