I got an array with some user date like this:
$users = array(
"bill@microsoft.com" => array(
"Name" => "Bill Gates",
"Password" => "12345",),
"jim@apple.com" => array(
"Name" => "Jim Franklyn",
"Password" => "98765"),
);
How can i easily check the following conditions:
a) does $_POST['email'] exist in the array (as a key!)? b) get the password
I know that in_array doesn't work with multi arrays, also it should not search the whole array incl. sub arrays for the email - only the "key".
Is the only way to "foreach"?