Jump to content

If statment issue


Shadowing

Recommended Posts

This if statment is coming up true when its suppose to be false

Only reason I can think of is there is a ton of rows with id matching $_session['user_id']

which doesnt make any sense to me

 

 

 <?php 
				$check3 = "SELECT id FROM pm WHERE id='".mysql_real_escape_string($_SESSION['user_id'])."'"; 
				$check2 = mysql_query($check3) or die(mysql_error());
				$check1 = mysql_num_rows($check2);
if(empty($check1['id'])){		
	echo "Your Inbox is Empty";

}
?> 

Link to comment
https://forums.phpfreaks.com/topic/253818-if-statment-issue/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.