Array sort question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



 
Hi,
How can I sort a 2 dimensional array by number of elements?
Ex:
 
rgArray[0] = ("1","2");
rgArray[1] = ("1");
rgArray[2] = ("1","2","3","4");
rgArray[3] = ("1","2","3");
 
Now I would like to sort it so I can loop through them from least elements to most (or vice versa):
 
rgArray[1]   (now rgArray[0])    1
rgArray[0]   (now rgArray[1])    1,2
rgArray[3]   (now rgArray[2])    1,2,3
rgArray[2]   (now rgArray[3])    1,2,3,4
 
 
Thanks.
 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.375 / Virus Database: 268.1.1/271 - Release Date: 2/28/2006

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux