In JavaScript, the == operator isn\'t necessarily transitive:
==
js> \'0\' == 0 true js> 0 == \'\' true js> \'0\' == \'\' false
No, the == operator is not transitive.
The exact same scenario gives the same result in PHP.
echo var_dump('0'==0); echo var_dump(0==''); echo var_dump('0'=='');
yields:
boolean true boolean true boolean false