Hello,
I am trying to find the code to see if a result exists, and to do stuff if it doesnt. In this case I am trying to see if there is an entry for the current $user_id in band_page.
$checkbn = "SELECT * from band_page WHERE bandid='$user_id'";
$rs = mysql_query($checkbn, $conn) or die(mysql_error());
$bandid = mysql_fetch_assoc($rs);
if(mysql_num_rows($bandid)){
But it gives me this:
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /home/public_html/page.php on line 13
Thanks