I am trying to select data from a MySQL table, but I get one of the following error messages:
mysql_fetch_array() expects parameter 1 to be resource,
$username = $_POST['username']; $password = $_POST['password']; $result = mysql_query("SELECT * FROM Users WHERE UserName LIKE '%$username%'") or die(mysql_error()); while($row = mysql_fetch_array($result)) { echo $row['FirstName']; }
Sometimes suppressing the query as @mysql_query(your query);
@mysql_query(your query);