Maybe use sort(), asort(), or array_multisort()? I'm sure one of them would do what you're looking for.
asort() http://www.php.net/manual/en/function.asort.php sort() http://www.php.net/manual/en/function.sort.php array_multisort() http://www.php.net/manual/en/function.array-multisort.php Jason Soza ----- Original Message ----- From: "R.S. Herhuth" <[EMAIL PROTECTED]> Date: Thursday, July 25, 2002 11:09 am Subject: [PHP-WIN] Brain Twister > > I have a series of offices (11 at the present time). Each office > has a > CITY STATE ZIPCODE and a MILEAGE. What I need to do is to sort > them by > mileage which is dynamically calculated earlier in the script. I need > the offices to be stored in an array and sorted by the MILEAGE after > which I will return them in the order that they have been sorted. > > How can I do this? > > Ron > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php