Here is my code:
$usersql = "Select fab2_type from feesys_admin where adminname ='$_POST[username]' and adminemail = '$_POST[password]'";
$userresult = mysql_query($usersql) or die ("<h3>Error in query: $query. ".mysql_error()."</h3>");
$num_rows = mysql_num_rows($userresult);
if($num_rows > 0) {
if($userresult['fab2_type']=='Partner'){
}
When I run the SQL statement on the database through PHP Admin, it works fine. But it returns empty within the results here.
I checked to make sure the database connects fine. I checked all spelling Number of rows returns correctly. No syntax errors. When I echo the username and password and the sql statement, it's all correct.
This code used to work so I have no idea what's going wrong here.