Can anyone offer any help as to why the following code does not retrieve information from MySQL database? I get an error message that says "Warning: Supplied argument is not a valid MySQL result resource in /home/virtual/site522/fst/var/www/html/mysql1.php on line 16":
<?
$linkID = @mysql_pconnect(localhost, "", "");
mysql_select_db(dbname, $linkID);
$resultID = mysql_query("SELECT * FROM product", $linkID);
print "<table border=1><tr><th>Name:</th>";
print "<th>Quantity:</th><th>Price</th></tr>";
while ($row = mysql_fetch_row($resultID))
{
print "<tr>";
foreach ($row as $field)
{
print "<td>$field</td>";
}
print "<tr>";
}
print "</table>";
mysql_close($linkID);
?>
Thanks in advance for any help.