我有一个这样的数组数组:
Array(
[id1] => Array (
/* details */
[unique] => 3
)
[id2] => Array (
/* details */
[unique] => 5
[id3] => Array (
/* details */
[unique] => 1
)
)
问题:我如何按unique
字段对其进行排序,以便将其转换为如下所示?
Array(
[id2] => Array (
/* details */
[unique] => 5
)
[id1] => Array (
/* details */
[unique] => 3
[id3] => Array (
/* details */
[unique] => 1
)
)