Array Sorting

Ask about general coding issues or problems here.

Moderators: egami, macek, gesf

Post Reply
bonkers
New php-forum User
New php-forum User
Posts: 45
Joined: Wed Mar 12, 2003 7:17 pm

Wed Jun 04, 2003 5:33 pm

How can I sort an array with this information by number.
It's a 2d array, containing information like this:

Array
(
[1] => Array
(
[0] => 2
[1] => 1
[2] => 3
[3] => 1
[4] => 1
)

[0] => Array
(
[0] => http://www.extremeautofest.com
[1] => http://www.hondahookup.com
[2] => http://www.carandmodel.com
[3] => http://www.cardomain.com
[4] => http://www.importtuner.com
)

)

I want to rearrange it so that the corralating URL (like http://www.extremeautofest.com/ is to 2) is sorted by how big each one, the one with the largest number at the top. Is this possible with any of the array functions?

User avatar
WiZARD
Moderator
Moderator
Posts: 1240
Joined: Thu Jun 20, 2002 10:14 pm
Location: Ukraine, Crimea, Simferopol
Contact:

Thu Jun 05, 2003 1:57 am

"Sex,Drugs and Rock&Roll " replaced at "Sucks,Bugs and Plug&Play";
Image

Post Reply
  • Information
  • Who is online

    Users browsing this forum: No registered users and 3 guests