php multidim array key sort
php multidim array key sort
Out of context: Reply #1
- Started
- Last post
- 2 Responses
- Rickbass0
Maybe my brain is small, but can you give us an example?
Can't you do something like this:
// Sort the 'first level' array
$array = sort($array);// Initiate the sorted array:
$sortedarray = array();foreach($array as $key => $subarray) {
$sortedarray[$key] = sort($subarray);
}