You are here

function og_notifications_menu in Organic groups 6

Same name and namespace in other branches
  1. 5.8 og_notifications/og_notifications.module \og_notifications_menu()
  2. 5 og_notifications/og_notifications.module \og_notifications_menu()
  3. 5.3 og_notifications/og_notifications.module \og_notifications_menu()
  4. 5.7 og_notifications/og_notifications.module \og_notifications_menu()
  5. 6.2 modules/og_notifications/og_notifications.module \og_notifications_menu()

Implementation of hook_menu().

File

modules/og_notifications/og_notifications.module, line 25
Provide notifications and messaging support for organic groups.

Code

function og_notifications_menu() {
  $items = array();
  $items['user/%user/notifications/group'] = array(
    'title' => 'Groups',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'og_notifications_user_page',
      1,
    ),
    'access callback' => 'notifications_content_access',
    'access arguments' => array(
      1,
      'subscribe to content in groups',
    ),
    'type' => MENU_LOCAL_TASK,
    'weight' => 10,
  );

  // grouptype redirects to group.
  $items['user/%user/notifications/grouptype'] = array(
    'page callback' => 'og_notifications_grouptype_user_page',
    'page arguments' => array(
      1,
    ),
    'access callback' => 'notifications_content_access',
    'access arguments' => array(
      1,
      'subscribe to content in groups',
    ),
    'type' => MENU_CALLBACK,
  );
  return $items;
}