Web Analytics Made Easy -
StatCounter How to sort this multi dimensional array? - CodingForum

Announcement

Collapse
No announcement yet.

How to sort this multi dimensional array?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to sort this multi dimensional array?

    $data[][][][][60]='orange';
    $data[][][][][90]='apple';
    $data[][][][][30]='grapes';

    I want to sort it with the last key.With this array above, I want to output first value that has largestest key. Since apple has 90 key. It should be the output first :

    apple
    orange
    grapes

  • #2
    PHP: krsort - Manual
    The computer is always right. The computer is always right. The computer is always right. Take it from someone who has programmed for over ten years: not once has the computational mechanism of the machine malfunctioned.
    André Behrens, NY Times Software Developer

    Comment

    Working...
    X