diff options
author | rvelices <rv-github@modusoptimus.com> | 2012-01-12 20:50:46 +0000 |
---|---|---|
committer | rvelices <rv-github@modusoptimus.com> | 2012-01-12 20:50:46 +0000 |
commit | 6a115001ba122c2084e28353e025f7c8c5f62335 (patch) | |
tree | b6c15c78fc725c9d87ce7ded08d67e6d612fc362 /include | |
parent | 65590487d4f07d81a3e47899c2454df187d3f23a (diff) |
bug 2553 hide menubar/register on indentification page if gallery is locked or guest_access is false
git-svn-id: http://piwigo.org/svn/trunk@12878 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'include')
-rw-r--r-- | include/functions.inc.php | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/include/functions.inc.php b/include/functions.inc.php index 85cf7c902..4647e8845 100644 --- a/include/functions.inc.php +++ b/include/functions.inc.php @@ -2,7 +2,7 @@ // +-----------------------------------------------------------------------+ // | Piwigo - a PHP based photo gallery | // +-----------------------------------------------------------------------+ -// | Copyright(C) 2008-2011 Piwigo Team http://piwigo.org | +// | Copyright(C) 2008-2012 Piwigo Team http://piwigo.org | // | Copyright(C) 2003-2008 PhpWebGallery Team http://phpwebgallery.net | // | Copyright(C) 2002-2003 Pierrick LE GALL http://le-gall.net/pierrick | // +-----------------------------------------------------------------------+ @@ -1076,14 +1076,17 @@ SELECT param, value while ($row = pwg_db_fetch_assoc($result)) { - $conf[ $row['param'] ] = isset($row['value']) ? $row['value'] : ''; - - // 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') + $val = isset($row['value']) ? $row['value'] : ''; + // If the field is true or false, the variable is transformed into a boolean value. + if ($val == 'true') + { + $val = true; + } + elseif ($val == 'false') { - $conf[ $row['param'] ] = get_boolean($conf[ $row['param'] ]); + $val = false; } + $conf[ $row['param'] ] = $val; } } |