note 102515 added to types.comparisons
| From: | mauritsdajong at gmail dot com | Date: | Fri, 18 Feb 2011 15:12:13 +0000 |
| Subject: | note 102515 added to types.comparisons | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-177115@lists.php.net to get a copy of this message | ||
When we're doing loose comparisons (with double equals signs), the following fact is
interesting.
false == array() evaluates to true
false == "" evaluates to true
array() == "" however, evaluates to false
----
Server IP: 69.147.83.197
Probable Submitter: 81.204.231.175
----
Manual Page -- http://www.php.net/manual/en/types.comparisons.php
Edit -- https://master.php.net/note/edit/102515
Del: integrated -- https://master.php.net/note/delete/102515/integrated
Del: useless -- https://master.php.net/note/delete/102515/useless
Del: bad code -- https://master.php.net/note/delete/102515/bad+code
Del: spam -- https://master.php.net/note/delete/102515/spam
Del: non-english -- https://master.php.net/note/delete/102515/non-english
Del: in docs -- https://master.php.net/note/delete/102515/in+docs
Del: other reasons-- https://master.php.net/note/delete/102515
Reject -- https://master.php.net/note/reject/102515
Search -- https://master.php.net/manage/user-notes.php