From 384ec739f6c11ab82f9a57e9398e954206c7a7ca Mon Sep 17 00:00:00 2001 From: gweltas Date: Thu, 15 Jan 2004 17:06:45 +0000 Subject: Correction of php warnings git-svn-id: http://piwigo.org/svn/branches/release-1_3@280 68402e56-0260-453c-a942-63ccdbb3a9ee --- picture.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'picture.php') diff --git a/picture.php b/picture.php index 49aa9fd70..a862af03b 100644 --- a/picture.php +++ b/picture.php @@ -71,7 +71,8 @@ $page['date_creation'] = $row['date_creation']; $page['filesize'] = $row['filesize']; $page['width'] = $row['width']; $page['height'] = $row['height']; -$page['category_id'] = $row['category_id']; +if (is_numeric( $page['cat'] )) + $page['category_id'] = $row['category_id']; $page['keywords'] = $row['keywords']; $page['storage_category_id'] = $row['storage_category_id']; // retrieving the number of the picture in its category (in order) @@ -492,7 +493,7 @@ if ( $page['num'] < $page['cat_nb_images']-1 ) $result = mysql_query( $query ); $row = mysql_fetch_array( $result ); - if ( $array_cat_directories[$row['storage_category_id']] == '' ) + if ( !isset($array_cat_directories[$row['storage_category_id']])) { $array_cat_directories[$row['storage_category_id']] = get_complete_dir( $row['storage_category_id'] ); -- cgit v1.2.3