note 15734 deleted from control-structures by jimw

From: Date: Thu, 20 Dec 2001 23:17:22 +0000
Subject: note 15734 deleted from control-structures by jimw
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-23549@lists.php.net to get a copy of this message
Things that will evaluate to false: 1) integer with a value = 0 ($foo = 0;) 2) assigning FALSE to a variable ($foo = false;) 3) empty string ($foo = '';) 4) string containing 0 ($foo = '0';) 5) variable assigned the NULL value ($foo = NULL;) 6) a variable not defined (isset($foo);) 7) Any expression evaluating to one of prementioned points Side note, remember that NULL and 0 are not the same thing, but WILL both be evaluated to false. Also, because PHP is weakly typed, points 1 and 4 pretty much mean the same thing.

« previous php.notes (#23549) next »