Bug #11627 Updated: string '0' treated as empty
| From: | brianlmoon@php.net | Date: | Sun, 24 Jun 2001 16:16:47 +0000 |
| Subject: | Bug #11627 Updated: string '0' treated as empty | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-57840@lists.php.net to get a copy of this message | ||
ID: 11627
Updated by: brianlmoon
Reported By: vgo@nrd.lt
Status: Closed
Bug Type: Unknown/Other Function
Operating system:
PHP Version: 4.0.5
Assigned To:
Comments:
Actually, you should get an error on that line.
empty takes a variable, not a value.
Previous Comments:
---------------------------------------------------------------------------
[2001-06-23 14:29:39] sniper@php.net
Yes, this is intentional. Check the manual page for it:
http://www.php.net/empty
---------------------------------------------------------------------------
[2001-06-23 07:54:37] vgo@nrd.lt
the string '0' is not empty but treated as empty
if( empty( '0' ) )
{
}
---------------------------------------------------------------------------
ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=11627&edit=2