note 7616 modified in empty by danbeck
| From: | danbeck@php.net | Date: | Wed, 20 Sep 2000 10:01:57 +0000 |
| Subject: | note 7616 modified in empty by danbeck | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-5218@lists.php.net to get a copy of this message | ||
Here are a few tests with empty:
$a = 0 ; print empty($a) ? "TRUE" : "FALSE"; //TRUE
$b = "0" ; print empty($b) ? "TRUE" : "FALSE"; //TRUE
$c = "" ; print empty($c) ? "TRUE" : "FALSE"; //TRUE
$d = 1 ; print empty($d) ? "TRUE" : "FALSE"; //FALSE
print empty($e) ? "TRUE" : "FALSE"; //TRUE
$f= TRUE ; print empty($f) ? "TRUE" : "FALSE"; //FALSE
$g= FALSE; print empty($g) ? "TRUE" : "FALSE"; //TRUE
$h=array();print empty($h) ? "TRUE" : "FALSE"; //TRUE
http://www.php.net/manual/function.empty.php