For example, I have a multidimensional array, to be simple I will use a 3 dimensional array as example like the following
$array[0][0][1]=1;
$array[0][0][2]=3;
$array[1][1][1]=5;
$array[1][1][2]=7;
I am looking for a simple function, I can input the $array as the parameter, and return the values a new_array with values {1, 3, 5, 7}
Somehow recursively call the array_values function until the element value it returs is not an array?
Is there a built in array function for this purpose?
Thanks!