Why does this always return true:
true
$s = \'334rr\'; $i = (int)$s; if ($i == $s) { echo true; } else { echo false; }
If I ec
PHP converts the $s string to an integer when comparing to another integer ($i). It basically does this (well, i don't know what it does internally, but it boils down to this):
if($i == (int) $s)
Which makes the statement true