Ninjakreborn Posted September 10, 2009 Share Posted September 10, 2009 Array ( [Netopia Communications] => Array ( [text] => Netopia Communications [count] => 1 ) [www.netopia.com] => Array ( [text] => www.netopia.com [count] => 2 ) [Timbuktu] => Array ( [text] => Timbuktu [count] => 12 ) [Motorola] => Array ( [text] => Motorola [count] => 3 ) [Purchase Wireless PC Card] => Array ( [text] => Purchase Wireless PC Card [count] => 1 ) [Timbuktu ] => Array ( [text] => Timbuktu [count] => 1 ) [Timbuktu Pro] => Array ( [text] => Timbuktu Pro [count] => 9 ) [ Netopia netOctopus] => Array ( [text] => Netopia netOctopus [count] => 1 ) [service Assurance platform] => Array ( [text] => Service Assurance platform [count] => 1 ) [Netopia, Inc.] => Array ( [text] => Netopia, Inc. [count] => 1 ) [Netopia] => Array ( [text] => Netopia [count] => 1 ) [Netopia] => Array ( [text] => Netopia [count] => 1 ) [netOctupus] => Array ( [text] => netOctupus [count] => 1 ) [7347 VDSL Residential Gateway] => Array ( [text] => 7347 VDSL Residential Gateway [count] => 1 ) [Timbuktu Pro] => Array ( [text] => Timbuktu Pro [count] => 1 ) [Netopia] => Array ( [text] => Netopia [count] => 12 ) [Timbuktu 8.1.1] => Array ( [text] => Timbuktu 8.1.1 [count] => 1 ) [Timbuktu Pro 5.0] => Array ( [text] => Timbuktu Pro 5.0 [count] => 1 ) [Timbuktu Pro page] => Array ( [text] => Timbuktu Pro page [count] => 1 ) [Timbuktu Mac upgrade page] => Array ( [text] => Timbuktu Mac upgrade page [count] => 1 ) [Timbuktu Pro 8.6] => Array ( [text] => Timbuktu Pro 8.6 [count] => 1 ) [Timbuktu Pro for Mac OS] => Array ( [text] => Timbuktu Pro for Mac OS [count] => 1 ) [Timbuktu Pro for Windows] => Array ( [text] => Timbuktu Pro for Windows [count] => 1 ) [Netopia R-Series] => Array ( [text] => Netopia R-Series [count] => 1 ) [configure Windows NT 4.0 RAS for dial-in use with Timbuktu Pro 32] => Array ( [text] => configure Windows NT 4.0 RAS for dial-in use with Timbuktu Pro 32 [count] => 1 ) [Timbuktu Pro for Macintosh 5.21] => Array ( [text] => Timbuktu Pro for Macintosh 5.21 [count] => 1 ) [Netopia IPSec Compatibility] => Array ( [text] => Netopia IPSec Compatibility [count] => 1 ) [Netopia R-series router can act as a PPTP server] => Array ( [text] => Netopia R-series router can act as a PPTP server [count] => 1 ) [Netopia's R2121 Dual Analog Router] => Array ( [text] => Netopia's R2121 Dual Analog Router [count] => 1 ) [NBBS Demo (html)] => Array ( [text] => NBBS Demo (html) [count] => 2 ) [support and Feedback Form] => Array ( [text] => Support and Feedback Form [count] => 1 ) [Netopia Routers] => Array ( [text] => Netopia Routers [count] => 2 ) [Timbuktu Pro] => Array ( [text] => Timbuktu Pro [count] => 1 ) [Download Page ] => Array ( [text] => Download Page [count] => 2 ) [Home Page] => Array ( [text] => Home Page [count] => 3 ) [Downloads Page] => Array ( [text] => Downloads Page [count] => 1 ) [TER/GCBA-N1 TER/GCBA-E1] => Array ( [text] => TER/GCBA-N1 TER/GCBA-E1 [count] => 1 ) [TER/GUSB-N1 TER/GUSB-E1] => Array ( [text] => TER/GUSB-N1 TER/GUSB-E1 [count] => 1 ) [Find out more] => Array ( [text] => Find out more [count] => 1 ) [Timbuktu Pro 8.7] => Array ( [text] => Timbuktu Pro 8.7 [count] => 1 ) [buy Now] => Array ( [text] => Buy Now [count] => 2 ) [upgrade] => Array ( [text] => Upgrade [count] => 1 ) [upgrade ] => Array ( [text] => Upgrade [count] => 1 ) [Windows Vista and Timbuktu Pro] => Array ( [text] => Windows Vista and Timbuktu Pro [count] => 1 ) [ Netopia] => Array ( [text] => Netopia [count] => 1 ) [ R2020 Dual Analog Router] => Array ( [text] => R2020 Dual Analog Router [count] => 1 ) [Netopia technote] => Array ( [text] => Netopia technote [count] => 6 ) [MISC] => Array ( [text] => MISC [count] => 1 ) [OTHER-REF] => Array ( [text] => OTHER-REF [count] => 1 ) [The Standardization of VDSL2] => Array ( [text] => The Standardization of VDSL2 [count] => 1 ) [Homepage] => Array ( [text] => Homepage [count] => 1 ) [Firewall Issues] => Array ( [text] => Firewall Issues [count] => 1 ) [How to connect to a system behind a router running Network Address Translation (NAT)] => Array ( [text] => How to connect to a system behind a router running Network Address Translation (NAT) [count] => 1 ) [What's New in Timbuktu Pro for Macintosh?] => Array ( [text] => What's New in Timbuktu Pro for Macintosh? [count] => 1 ) [Timbuktu home page] => Array ( [text] => Timbuktu home page [count] => 1 ) [Netopia's] => Array ( [text] => Netopia's [count] => 1 ) [Netopia Products] => Array ( [text] => Netopia Products [count] => 1 ) [Timbuktu Pro for the Education Market] => Array ( [text] => Timbuktu Pro for the Education Market [count] => 1 ) [Timbuktu software] => Array ( [text] => Timbuktu software [count] => 1 ) ) Is there a way to sort this master array by the count value in the subarray. I want to sort the entire array based off of this number in Descending order. Is that possible? If so, any advice pertaining to how? Link to comment https://forums.phpfreaks.com/topic/173812-solved-sort-by-sub-value/ Share on other sites More sharing options...
Daniel0 Posted September 10, 2009 Share Posted September 10, 2009 usort Link to comment https://forums.phpfreaks.com/topic/173812-solved-sort-by-sub-value/#findComment-916218 Share on other sites More sharing options...
Ninjakreborn Posted September 10, 2009 Author Share Posted September 10, 2009 function sortfunction($a, $b) { return $a['count'] < $b['count']; } usort($anchor_master, 'sortfunction'); Perfect, thanks. Link to comment https://forums.phpfreaks.com/topic/173812-solved-sort-by-sub-value/#findComment-916227 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.