How to sort following array in descending order by sorder
? The whole array is considered to be one array for descending sorting.I see some other questions like this but none of them helped me.
Array
(
[0] => Array
(
[0] => Array
(
[id] => 2208
[status] => u13333333333333
[user_id] => 6
[sorder] => 3
)
[1] => Array
(
[id] => 2208
[status] => user111111111111111
[user_id] => 6
[sorder] => 1
)
)
[1] => Array
(
[0] => Array
(
[id] => 2209
[status] => u222222222222222222222
[user_id] => 5
[sorder] => 2
)
)
)
Edit May be this is another form of the array in two dimensional.
Array
(
[userPosts] => Array
(
[0] => Array
(
[0] => Array
(
[id] => 2208
[status] => u13333333333333
[user_id] => 2208
[sorder] => 3
)
[1] => Array
(
[id] => 2208
[status] => user111111111111111
[user_id] => 2208
[sorder] => 1
)
)
[1] => Array
(
[0] => Array
(
[id] => 2209
[status] => u222222222222222222222
[user_id] => 2209
[sorder] => 2
)
)
)
)