damned "false"
| From: | Rad0s-ław Gajewski | Date: | Thu, 01 Jan 1970 00:00:00 +0000 |
| Subject: | damned "false" | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-108633@lists.php.net to get a copy of this message | ||
I am not very happy how generaly boolean comparison is solved in
PHP...but I checked different stuff and like this shouldn't be:
----
<?
$a="null";
if ($a="dwa") { // one sign = so it is OK
echo "OK";
}
if ($a=true) {
echo "OK";
}
if ($a=false) {
echo "OK"; //but it is not written!!!!!!!
}
?>
I tested it in PHP4.2.0 (LINUX)
--
--
pozdr
Rad0s
Radek Gajewski rgajew@sgh.waw.pl GG:694459 ICQ:110153822
--------------------------------------------------------