diff options
| author | Andreas Fischer <bantu@phpbb.com> | 2011-11-14 15:46:58 +0100 |
|---|---|---|
| committer | Andreas Fischer <bantu@phpbb.com> | 2011-11-14 15:46:58 +0100 |
| commit | 34ed1352a63ece56185410385a81d881beb25731 (patch) | |
| tree | 7e555a2c19dadaf62a87ecc41f3a513628d90caf /phpBB/install/install_install.php | |
| parent | b21e343b5e80f2c6404fd94ff2a10c3a31d360e0 (diff) | |
| parent | f31da015fcad1efb792e78462af7eb56e1abcabc (diff) | |
| download | forums-34ed1352a63ece56185410385a81d881beb25731.tar forums-34ed1352a63ece56185410385a81d881beb25731.tar.gz forums-34ed1352a63ece56185410385a81d881beb25731.tar.bz2 forums-34ed1352a63ece56185410385a81d881beb25731.tar.xz forums-34ed1352a63ece56185410385a81d881beb25731.zip | |
Merge branch 'develop-olympus' into develop
* develop-olympus:
[ticket/9066] Move regex into get_preg_expression function and add tests
[ticket/9066] Disallow some database prefix to prevent same errors and problems
Diffstat (limited to 'phpBB/install/install_install.php')
| -rw-r--r-- | phpBB/install/install_install.php | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/phpBB/install/install_install.php b/phpBB/install/install_install.php index 439bebf27e..722b5ddebd 100644 --- a/phpBB/install/install_install.php +++ b/phpBB/install/install_install.php @@ -546,6 +546,11 @@ class install_install extends module $error[] = $lang['INST_ERR_NO_DB']; $connect_test = false; } + else if (!preg_match(get_preg_expression('table_prefix'), $data['table_prefix'])) + { + $error[] = $lang['INST_ERR_DB_INVALID_PREFIX']; + $connect_test = false; + } else { $connect_test = connect_check_db(true, $error, $available_dbms[$data['dbms']], $data['table_prefix'], $data['dbhost'], $data['dbuser'], htmlspecialchars_decode($data['dbpasswd']), $data['dbname'], $data['dbport']); @@ -1916,7 +1921,7 @@ class install_install extends module 'dbname' => array('lang' => 'DB_NAME', 'type' => 'text:25:100', 'explain' => false), 'dbuser' => array('lang' => 'DB_USERNAME', 'type' => 'text:25:100', 'explain' => false), 'dbpasswd' => array('lang' => 'DB_PASSWORD', 'type' => 'password:25:100', 'explain' => false), - 'table_prefix' => array('lang' => 'TABLE_PREFIX', 'type' => 'text:25:100', 'explain' => false), + 'table_prefix' => array('lang' => 'TABLE_PREFIX', 'type' => 'text:25:100', 'explain' => true), ); var $admin_config_options = array( 'legend1' => 'ADMIN_CONFIG', |
