Find key in nested associative array
问题 The other day I asked a question related to this, and I got an answer, but it did not do what I wanted. Here is the method I have for traversing a multidimensional associative array, checking whether a key is in the array (from the answer to my previous question): private function checkKeyIsInArray($dataItemName, $array) { foreach ($array as $key => $value) { // convert $key to string to prevent key type convertion echo '<pre>The key: '.(string) $key.'</pre>'; if ((string)$key ==