RE: [PHP] Found a PHP bug!!!!!!!!!

From: Date: Mon, 27 Jan 2003 20:58:48 +0000
Subject: RE: [PHP] Found a PHP bug!!!!!!!!!
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-133297@lists.php.net to get a copy of this message
John. > Actually, "08" is equal to 8 in PHP. PHP will convert the string to an >integer and the two will compare as equal. No they are not equal. Yes, PHP will do the conversion so that they are equal. That does not refute the fact that logically '08' != 8. > Someone already posted why the problem was happening, because the numbers > were being converted to invalid octal numbers and being set to zero. I understand the problem at hand. (and did when I posted) However, if Scott had been doing the conversions manually, he would never have run across this problem. It is a bad idea to rely on the language (whatever the language) to do automatic variable conversions. =C=

« previous php.general (#133297) next »