1

我有以下二维数组:

Array (
[ID] => Array
    (
        [0] => 150
        [1] => 250
    )

[Group] => Array
    (
        [0] => 120
        [1] => 120
    )

[Name] => Array
    (
        [0] => Name 1
        [1] => Name 2
    )

[Price] => Array
    (
        [0] => 9.99
        [1] => 11.99
    )

[Date] => Array
    (
        [0] => 12.04.2013
        [1] => 11.04.2013
    )

[SortIndex] => Array
    (
        [0] => 20
        [1] => 10
    )

)

我想在 SortIndex-Array 升序之后对它们进行排序。但是数组中的不同值与其他值相关。因此无法更改关联。我怎样才能对它们进行排序?

4

1 回答 1

1

有没有理由不将数组转换为更合适的形式?

Array (
[0] => Array
    (
        [ID] => 150
        [Group] => 120
    )

[1] => Array
    (
        [ID] => 250
        [GROUP] => 120
    )
....
于 2013-04-22T10:33:25.277 回答