Edit report at https://bugs.php.net/bug.php?id=63220&edit=1
ID: 63220 Updated by: pierr...@php.net Reported by: ellyx at dewata-production dot com Summary: Camparison Operator -Status: Open +Status: Not a bug Type: Bug Package: *General Issues Operating System: Opensuse 12.1 PHP Version: 5.3.7 Block user comment: N Private report: N New Comment: Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php http://www.php.net/manual/fr/types.comparisons.php Previous Comments: ------------------------------------------------------------------------ [2012-10-05 03:23:14] ellyx at dewata-production dot com I think it not just the comparison with string 'ids', i think this happen in every string end with 'ids' for example var_dump(0 == 'testIds'); Expected: false Actual: true ------------------------------------------------------------------------ [2012-10-05 03:16:38] ellyx at dewata-production dot com Description: ------------ I think there is a bug in comparison operator, when i compare 0 with string 'ids' it return true, it should be return false Test script: --------------- var_dump(0 == 'ids') if(0 == 'ids'){ echo 'true'; } $str = 'ids'; if(0 == $str){ echo 'test'; } Expected result: ---------------- false Actual result: -------------- true 'true' 'test' ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=63220&edit=1