diff options
author | nikrou <nikrou@piwigo.org> | 2009-11-15 12:26:09 +0000 |
---|---|---|
committer | nikrou <nikrou@piwigo.org> | 2009-11-15 12:26:09 +0000 |
commit | 1040cae2104259fdec8543e0a41ac63cbe24c69c (patch) | |
tree | f1a08573c7d2bdf1b8634263226fd42de7088848 /admin/cat_perm.php | |
parent | dda7f4571b72323c4e53ce5ef4a42412b65da3bd (diff) |
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
Diffstat (limited to 'admin/cat_perm.php')
-rw-r--r-- | admin/cat_perm.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/admin/cat_perm.php b/admin/cat_perm.php index ed0257bc4..0107d6cc7 100644 --- a/admin/cat_perm.php +++ b/admin/cat_perm.php @@ -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']])) { |