I'm a little bit confused about truth
in PHP.
My understanding is that 0 evaluates to false, and non-empty strings (unless the string is "0") evaluate to true.
This is as I expect:
var_dump((bool) 0); // prints "boolean false"
var_dump((bool) 'someString'); // prints "boolean true"
But then I am surprised by the following result:
var_dump((0=='someString')); // prints "boolean true"
My question is, why does 0=='someString'
evaluate to true?