From 924dd262ec3778277cf1efedee92fa5dd4fb2d32 Mon Sep 17 00:00:00 2001 From: nikrou Date: Fri, 20 Nov 2009 14:17:04 +0000 Subject: Feature 1244 resolved Replace all mysql functions in core code by ones independant of database engine Fix small php code synxtax : hash must be accessed with [ ] and not { }. git-svn-id: http://piwigo.org/svn/trunk@4325 68402e56-0260-453c-a942-63ccdbb3a9ee --- admin/cat_modify.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'admin/cat_modify.php') diff --git a/admin/cat_modify.php b/admin/cat_modify.php index 1ca146aa6..06a001253 100644 --- a/admin/cat_modify.php +++ b/admin/cat_modify.php @@ -193,7 +193,7 @@ SELECT * FROM '.CATEGORIES_TABLE.' WHERE id = '.$_GET['cat_id'].' ;'; -$category = mysql_fetch_assoc( pwg_query( $query ) ); +$category = pwg_db_fetch_assoc( pwg_query( $query ) ); // nullable fields foreach (array('comment','dir','site_id', 'id_uppercat') as $nullable) { @@ -210,7 +210,7 @@ $query = 'SELECT DISTINCT category_id WHERE category_id = '.$_GET['cat_id'].' LIMIT 1'; $result = pwg_query($query); -$category['has_images'] = mysql_num_rows($result)>0 ? true : false; +$category['has_images'] = pwg_db_num_rows($result)>0 ? true : false; // Navigation path $navigation = get_cat_display_name_cache( @@ -373,7 +373,7 @@ SELECT id,tn_ext,path FROM '.IMAGES_TABLE.' WHERE id = '.$category['representative_picture_id'].' ;'; - $row = mysql_fetch_assoc(pwg_query($query)); + $row = pwg_db_fetch_assoc(pwg_query($query)); $src = get_thumbnail_url($row); $url = get_root_url().'admin.php?page=picture_modify'; $url.= '&image_id='.$category['representative_picture_id']; @@ -461,9 +461,9 @@ SELECT id, file, path, tn_ext ;'; $result = pwg_query($query); - if (mysql_num_rows($result) > 0) + if (pwg_db_num_rows($result) > 0) { - $element = mysql_fetch_assoc($result); + $element = pwg_db_fetch_assoc($result); $img_url = '