ok i want to count the number of rows in a table and display the total.
This is the code i have so far
$result = mysql_query("SELECT COUNT(*) FROM table WHERE example ='0'");
$num_rows = mysql_fetch_row($result);
$num_rows = $num_rows;
echo "There are ".$num_rows." rows.";
i seem to be getting the following error
Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in