note 44968 added to types.comparisons
| From: | rabbott at calstatela dot edu | Date: | Sat, 21 Aug 2004 15:24:39 +0000 |
| Subject: | note 44968 added to types.comparisons | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-75060@lists.php.net to get a copy of this message | ||
So it looks like in comparison of two elements if either is a number, the other is cast to a number.
["x" == 0.0 is true]
If both are strings that can be cast to numbers they will be. ["005" == "5.00"
is true]
If only one can be cast to a number, neither will be. ["x" == "0" is false]
----
Manual Page -- http://www.php.net/manual/en/types.comparisons.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+44968
Delete -- http://master.php.net/manage/user-notes.php?action=delete+44968&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+44968&report=yes
Search -- http://master.php.net/manage/user-notes.php