Possible Duplicate: PHP custom sorting
I have an array,
Array
(
[Flag] => 2
[Pending] => 11
[Received] => 11
[Sent] => 8
[Skip] => 5
[Complaint] => 1
[Query] => 1
)
I have two requests for the above array:
How can I sort this into the order Received, Sent, Pending, Flag, Skip, Query, Request, Complaint.
As we see that "Request" is not available in the array, how do I push it into the array with the value zero?