Wednesday, May 05, 2010
Equality is Supposed to be Transitive
Equality is one of those operators that you expect to be transitive. In general, we expect that
ifSadly that's not always the case in PHP.
a=b
and
b=c
then
a=c
(1 == true) => true
(true == "true") => true
(1 == "true") => false