You are here

function og_notifications_user_page in Organic groups 5.3

Same name and namespace in other branches
  1. 5.8 og_notifications/og_notifications.module \og_notifications_user_page()
  2. 5 og_notifications/og_notifications.module \og_notifications_user_page()
  3. 5.7 og_notifications/og_notifications.module \og_notifications_user_page()
  4. 6.2 modules/og_notifications/og_notifications.pages.inc \og_notifications_user_page()
  5. 6 modules/og_notifications/og_notifications.module \og_notifications_user_page()

Menu callback: Display the user subscription management forms.

Parameters

Object $account: User object of the user whose page is to be displayed.

2 string references to 'og_notifications_user_page'
og_notifications_menu in og_notifications/og_notifications.module
Implementation of hook_menu().
og_notifications_notifications in og_notifications/og_notifications.module
Implementation of hook_notifications().

File

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

Code

function og_notifications_user_page($account = NULL) {
  global $user;
  $account = $account ? $account : $user;
  if (!empty($account->og_groups)) {
    return drupal_get_form('og_notifications_add_form', $account) . drupal_get_form('og_notifications_manage_form', $account);
  }
  else {
    drupal_set_message(t('There are no active group subscriptions available.'));
  }
}