Re-enabled fully dynamic config settings.

git-svn-id: file:///svn/phpbb/trunk@3360 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Ludovic Arnaud 2003-01-22 20:44:37 +00:00
parent 4be10373b8
commit 644735d9ac

View file

@ -148,13 +148,22 @@ $template = new template();
$db = new sql_db($dbhost, $dbuser, $dbpasswd, $dbname, $dbport, false);
// Grab global variables, re-cache if necessary
if (!($config = $cache->get('config')))
if ($config = $cache->get('config'))
{
$sql = 'SELECT *
FROM ' . CONFIG_TABLE . '
WHERE is_dynamic = 1';
$result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result))
{
$config[$row['config_name']] = $row['config_value'];
}
}
else
{
$config = array();
/*
WHERE is_dynamic = 1';
*/
$sql = 'SELECT *
FROM ' . CONFIG_TABLE;
$result = $db->sql_query($sql);