First, I have this multi dimensional array.
$array = array("user1" => array("name" => "Jason", "category" => "health"),
"user2" => array("name" => "Mechelle", "category" => "Politics"));
how can I retrieved the sub array's value base on its same sub array object without using a loop? like I want to get the value of the array object named "name" from the object array named "category" that has a value of health. My expected result is "Jason" because in the array where the array object named "name" that has a value of 'Jason' belongs to a same sub array named 'category' where the value is "health". Any help, ideas, clues, recommendations, suggestions please?
foreach?