Jump to content

array_multisort usage


rosenrosen

Recommended Posts

I think the answer to my question is array_multisort but I'm not sure how to use it and trial and error isn't working for me.

 

I have 2 associative arrays that get populated in loops as follows

 

$events[$id][$date]=$count

 

$names[$id][name]=$name

 

I want to sort $events based on the alphabetical name that appears in $names.  The first field of each array,"$id" is the key that relates the two chunks of information.  Thanks.

Link to comment
https://forums.phpfreaks.com/topic/150052-array_multisort-usage/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.