Оbject is converted to an one-dimensional array
function array_values_recursive($array) { $flat = array(); foreach ($array as $key=>$value)
{ if (is_array($value)) $flat = array_merge($flat, array_values_recursive($value)); else $flat[$key] = $value; } return $flat; }