If I had an array like:
$array[\'foo\'] = 400; $array[\'bar\'] = \'xyz\';
And I wanted to get the first item out of that array without knowing
Use reset() function to get the first item out of that array without knowing the key for it like this.
$value = array('foo' => 400, 'bar' => 'xyz'); echo reset($value);
output // 400