mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 14:18:52 +00:00
Fixed bug #120, stripslashes in config table from 1.x and fixed parse error
git-svn-id: file:///svn/phpbb/branches/phpBB-2_0_0@3217 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
d98cd83286
commit
bfc7f0c2ce
1 changed files with 5 additions and 3 deletions
|
@ -39,7 +39,7 @@ if ( !defined('INSTALLING') )
|
||||||
|
|
||||||
if( defined("PHPBB_INSTALLED") )
|
if( defined("PHPBB_INSTALLED") )
|
||||||
{
|
{
|
||||||
redirect("../index.$phpEx);
|
redirect("../index.$phpEx");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -565,9 +565,11 @@ if ( !empty($next) )
|
||||||
if ( !inarray($name, $ignore_configs) )
|
if ( !inarray($name, $ignore_configs) )
|
||||||
{
|
{
|
||||||
$name = ( !empty($rename_configs[$name]) ) ? $rename_configs[$name] : $name;
|
$name = ( !empty($rename_configs[$name]) ) ? $rename_configs[$name] : $name;
|
||||||
|
|
||||||
|
// phpBB 1.x has some problems with escaping strings in the database. Try to correct for
|
||||||
|
// this by removing all slashes and then escaping once.
|
||||||
$sql = "REPLACE INTO " . CONFIG_TABLE . " (config_name, config_value)
|
$sql = "REPLACE INTO " . CONFIG_TABLE . " (config_name, config_value)
|
||||||
VALUES ('$name', '" . stripslashes($value) . "')";
|
VALUES ('$name', '".addslashes(stripslashes(stripslashes($value)))."')";
|
||||||
query($sql, "Couldn't update config table with values from old config table");
|
query($sql, "Couldn't update config table with values from old config table");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue