The way PHP handles comparisons when multiple types are concerned is quite confusing.
For example:
"php" == 0
This is true, because the string is casted interally to an integer. Any string (that does not start with a number), when casted to an integer, will be 0.