function _mailchimp_list_cmp in Mailchimp 7.4
Same name and namespace in other branches
- 8 mailchimp.module \_mailchimp_list_cmp()
- 7.5 mailchimp.module \_mailchimp_list_cmp()
- 7.2 mailchimp.module \_mailchimp_list_cmp()
- 7.3 mailchimp.module \_mailchimp_list_cmp()
- 2.x mailchimp.module \_mailchimp_list_cmp()
Helper function used by uasort() to sort lists alphabetically by name.
Parameters
array $a: An array representing the first list.
array $b: An array representing the second list.
Return value
int One of the values -1, 0, 1
1 string reference to '_mailchimp_list_cmp'
- mailchimp_get_lists in ./
mailchimp.module - Gets Mailchimp lists. Can be filtered by an array of list IDs.
File
- ./
mailchimp.module, line 397 - Mailchimp module.
Code
function _mailchimp_list_cmp($a, $b) {
if ($a->name == $b->name) {
return 0;
}
return $a->name < $b->name ? -1 : 1;
}