mirror of
https://github.com/Piwigo/Piwigo.git
synced 2025-04-26 19:29:58 +03:00
Feature 1241 resolved. replace mysql_fetch_array by mysql_fetch_assoc for small php code improvements
git-svn-id: http://piwigo.org/svn/trunk@4265 68402e56-0260-453c-a942-63ccdbb3a9ee
This commit is contained in:
parent
dda7f4571b
commit
1040cae210
51 changed files with 136 additions and 136 deletions
|
@ -45,7 +45,7 @@ SELECT status
|
|||
FROM '.CATEGORIES_TABLE.'
|
||||
WHERE id = '.$_GET['cat'].'
|
||||
;';
|
||||
list($status) = mysql_fetch_array(pwg_query($query));
|
||||
list($status) = mysql_fetch_row(pwg_query($query));
|
||||
|
||||
if ('private' == $status)
|
||||
{
|
||||
|
@ -62,7 +62,7 @@ SELECT id
|
|||
LIMIT 0,1
|
||||
;';
|
||||
|
||||
list($page['cat']) = mysql_fetch_array(pwg_query($query));
|
||||
list($page['cat']) = mysql_fetch_row(pwg_query($query));
|
||||
}
|
||||
|
||||
// +-----------------------------------------------------------------------+
|
||||
|
@ -110,7 +110,7 @@ SELECT group_id, cat_id
|
|||
AND group_id IN ('.implode(',', $_POST['grant_groups']).')
|
||||
;';
|
||||
$result = pwg_query($query);
|
||||
while ($row = mysql_fetch_array($result))
|
||||
while ($row = mysql_fetch_assoc($result))
|
||||
{
|
||||
array_push($granteds[$row['cat_id']], $row['group_id']);
|
||||
}
|
||||
|
@ -169,7 +169,7 @@ SELECT user_id, cat_id
|
|||
AND user_id IN ('.implode(',', $_POST['grant_users']).')
|
||||
;';
|
||||
$result = pwg_query($query);
|
||||
while ($row = mysql_fetch_array($result))
|
||||
while ($row = mysql_fetch_assoc($result))
|
||||
{
|
||||
array_push($granteds[$row['cat_id']], $row['user_id']);
|
||||
}
|
||||
|
@ -274,7 +274,7 @@ SELECT user_id, group_id
|
|||
WHERE group_id IN ('.implode(',', $group_granted_ids).')
|
||||
';
|
||||
$result = pwg_query($query);
|
||||
while ($row = mysql_fetch_array($result))
|
||||
while ($row = mysql_fetch_assoc($result))
|
||||
{
|
||||
if (!isset($granted_groups[$row['group_id']]))
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue