Changeset 12878 for trunk/include


Ignore:
Timestamp:
Jan 12, 2012, 9:50:46 PM (12 years ago)
Author:
rvelices
Message:

bug 2553 hide menubar/register on indentification page if gallery is locked or guest_access is false

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/functions.inc.php

    r12870 r12878  
    33// | Piwigo - a PHP based photo gallery                                    |
    44// +-----------------------------------------------------------------------+
    5 // | Copyright(C) 2008-2011 Piwigo Team                  http://piwigo.org |
     5// | Copyright(C) 2008-2012 Piwigo Team                  http://piwigo.org |
    66// | Copyright(C) 2003-2008 PhpWebGallery Team    http://phpwebgallery.net |
    77// | Copyright(C) 2002-2003 Pierrick LE GALL   http://le-gall.net/pierrick |
     
    10771077  while ($row = pwg_db_fetch_assoc($result))
    10781078  {
    1079     $conf[ $row['param'] ] = isset($row['value']) ? $row['value'] : '';
    1080 
    1081     // If the field is true or false, the variable is transformed into a
    1082     // boolean value.
    1083     if ($conf[$row['param']] == 'true' or $conf[$row['param']] == 'false')
    1084     {
    1085       $conf[ $row['param'] ] = get_boolean($conf[ $row['param'] ]);
    1086     }
     1079    $val = isset($row['value']) ? $row['value'] : '';
     1080    // If the field is true or false, the variable is transformed into a boolean value.
     1081    if ($val == 'true')
     1082    {
     1083      $val = true;
     1084    }
     1085    elseif ($val == 'false')
     1086    {
     1087      $val = false;
     1088    }
     1089    $conf[ $row['param'] ] = $val;
    10871090  }
    10881091}
Note: See TracChangeset for help on using the changeset viewer.