arrays - php in_array() usage -
i have array of data , checking result using in_array() function, yet reason returning false???
here code:
var_dump($result); var_dump(in_array("result", $result));
and here output:
array(4) { ["timestamp"]=> string(29) "#wed jul 20 22:00:32 pdt 2011" ["cause"]=> string(34) "username , password not match" ["result"]=> string(5) "false" [""]=> null } bool(false)
i'm confused???
you looking key not value. want use function:
Comments
Post a Comment