summerpewp Posted January 15, 2011 Share Posted January 15, 2011 I have a statement $account = $_SESSION['account_id']; $postedby = $account_id; /*both echo out to the same number*/ if($account == $postedby){ echo "DELETE BUTTON"; } i echo'ed out both $account and $postedby and both return 1 but the if statement fails to read as true. HELP!!! thanks in advance! Quote Link to comment https://forums.phpfreaks.com/topic/224563-if-statement-not-returning-true/ Share on other sites More sharing options...
PFMaBiSmAd Posted January 15, 2011 Share Posted January 15, 2011 Try using var_dump() instead of echo and do it on the line right before the if() statement. Quote Link to comment https://forums.phpfreaks.com/topic/224563-if-statement-not-returning-true/#findComment-1159983 Share on other sites More sharing options...
summerpewp Posted January 15, 2011 Author Share Posted January 15, 2011 that solved my problem thanks! Quote Link to comment https://forums.phpfreaks.com/topic/224563-if-statement-not-returning-true/#findComment-1159999 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.