ID: 14127
Updated by: derick
Reported By: [EMAIL PROTECTED]
Old Status: Open
Status: Bogus
Bug Type: Scripting Engine problem
Operating System: windows2000/nt4 server
PHP Version: 4.0.6
New Comment:

THis is not a bug, the strings get converted to a number here. Because the number is 
too big as integer value, they are converted into a floating point number. 
Floatingpoint numbers are never so accurate, thus the comparison succeeds. Please use 
the === operator instead of the == operator to get the desired result.

Derick

Previous Comments:
------------------------------------------------------------------------

[2001-11-19 18:52:09] [EMAIL PROTECTED]

I have  a program ,work with windows2000/nt4 server and apache 1.3.22,php4.0.6

if ("32060199990000780"=="32060199990000782") {
 echo "ok<br>";
 }
 else {
 echo "not <br>";
 }
it comp is ok.
this is error ! (0==2)



------------------------------------------------------------------------



Edit this bug report at http://bugs.php.net/?id=14127&edit=1


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to