From 46900fece3a0ffb09a0a4fe58bae841a3978f79d Mon Sep 17 00:00:00 2001 From: plegall Date: Thu, 27 Apr 2006 21:05:07 +0000 Subject: bug 228 fixed one more time ;-): use boolean_to_string on $conf['newuser_default_enabled_high'] during user infos creation. Useless use of boolean_to_string on $conf['newcat_default_status'] was removed. modification: loading configuration parameter from database was moved to a dedicated function to be called from include/common.inc.php and from install.php. improvement: use of clean insert function during install. bug fixed: during user information creation, support new status webmaster/normal/guest instead of admin/guest. bug fixed: during install, no need to insert obsolete mail_webmaster configuration parameter. git-svn-id: http://piwigo.org/svn/branches/branch-1_6@1282 68402e56-0260-453c-a942-63ccdbb3a9ee --- include/common.inc.php | 27 +-------------------------- 1 file changed, 1 insertion(+), 26 deletions(-) (limited to 'include/common.inc.php') diff --git a/include/common.inc.php b/include/common.inc.php index f66d1ee7f..8aeafb7bf 100644 --- a/include/common.inc.php +++ b/include/common.inc.php @@ -162,32 +162,7 @@ SELECT id // Setup gallery wide options, if this fails then we output a CRITICAL_ERROR // since basic gallery information is not available // -$query = ' -SELECT param,value - FROM '.CONFIG_TABLE.' -;'; -if (!($result = pwg_query($query))) -{ - die("Could not query config information"); -} - -while ( $row =mysql_fetch_array( $result ) ) -{ - if ( isset( $row['value'] ) ) - { - $conf[$row['param']] = $row['value']; - } - else - { - $conf[$row['param']] = ''; - } - // If the field is true or false, the variable is transformed into a - // boolean value. - if ( $conf[$row['param']] == 'true' or $conf[$row['param']] == 'false' ) - { - $conf[$row['param']] = get_boolean( $conf[$row['param']] ); - } -} +load_conf_from_db(); include(PHPWG_ROOT_PATH.'include/user.inc.php'); -- cgit v1.2.3