Re: Php ignores if statement

From: Date: Sat, 22 Nov 2003 19:55:00 +0000
Subject: Re: Php ignores if statement
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-170682@lists.php.net to get a copy of this message
Pieter wrote:
I recently started coding online and i have the weirdest response, my code is: <?php include 'function.inc'; echo "$id<br>"; print (gettype($id)); if ($id = "add" ) { echo "is add"; exit; } <snip>
'=' sets value. '==' checks equality. http://www.php.net/manual/en/language.operators.comparison.php -- By-Tor.com It's all about the Rush http://www.by-tor.com

« previous php.general (#170682) next »