note 56482 deleted from function.empty by aidan

From: Date: Mon, 05 Sep 2005 06:11:57 +0000
Subject: note 56482 deleted from function.empty by aidan
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-94741@lists.php.net to get a copy of this message
Note Submitter: matt at braynard dot com Reason: useless ---- The empty() function is compared side-by-side with the isset() function but there is an important difference between them. While isset() allows for multiple variables to be evaluated: $a = "test"; $b = "anothertest"; var_dump(isset($a)); // TRUE var_dump(isset($a, $b)); // TRUE unset ($a); var_dump(isset($a)); // FALSE var_dump(isset($a, $b)); // FALSE However, you cannot use empty in a like way - it only evaluates one at a time. Maybe in the next version...

« previous php.notes (#94741) next »