I have an array $food like:
Array
(
[apple] => Array
(
[color] => red
[type] => fruit
)
[choco] => Array
(
[color] => brown
[type] => candy
)
)
Is there a function where I can do:
get_key($food, 0) and it would return index 0, apple
get_key($food, 1) returns choco