function mailchimp_activity_menu in Mailchimp 7.5
Same name and namespace in other branches
- 7.2 modules/mailchimp_activity/mailchimp_activity.module \mailchimp_activity_menu()
- 7.3 modules/mailchimp_activity/mailchimp_activity.module \mailchimp_activity_menu()
- 7.4 modules/mailchimp_activity/mailchimp_activity.module \mailchimp_activity_menu()
Implements hook_menu().
File
- modules/
mailchimp_activity/ mailchimp_activity.module, line 59 - Module file for mailchimp_activity.
Code
function mailchimp_activity_menu() {
$items = array();
$mailchimp_activity_entities = mailchimp_activity_load_entities();
foreach ($mailchimp_activity_entities as $mailchimp_activity_entity) {
$arg = substr_count($mailchimp_activity_entity->entity_path, '/');
$items[$mailchimp_activity_entity->entity_path . '%entity_object/mailchimp_activity'] = array(
'title' => 'MailChimp Activity',
'load arguments' => array(
$mailchimp_activity_entity->entity_type,
),
'page callback' => 'mailchimp_activity_page',
'page arguments' => array(
$arg,
$mailchimp_activity_entity,
),
'access callback' => 'mailchimp_activity_access',
'access arguments' => array(
$mailchimp_activity_entity,
),
'type' => MENU_LOCAL_TASK,
);
}
return $items;
}