I am using PHP to connect to a DB and than retrieve data and display it, and I am getting this error.
Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /mysite/preupload.php
I'm trying to follow a tutorial from a respected web design/development site yet I ran into this road bump.
Any help would be greatly appreciated
$result = mysql_query( "SELECT category_id,category_name FROM gallery_category" );
while( $row = mysql_fetch_array( $result ) )
{
$photo_category_list .=<<<HTML
<option value="$row[0]">$row[1]</option>\n
HTML;
}
mysql_free_result( $result );