我想在特定的入口处获取关联PHP数组的KEY值。具体而言,我知道我需要的KEY是数组中第二个条目的键。
示例:
```html
示例:
```html
I want to get the value of the KEY of an associative PHP array at a specific entry. Specifically, I know the KEY I need is the key to the second entry in the array.
Example:
```$array = array('customer' => 'Joe', 'phone' => '555-555-5555');
我正在构建的内容非常动态,所以我不知道第二个条目是'phone'。有没有一种简单的方法来获取它?
简而言之,(我知道这样做不起作用,但是...)我正在寻找与以下功能等效的东西:key($array[1]);