You are here

function notifications_token_list in Notifications 6.3

Same name and namespace in other branches
  1. 5 notifications.module \notifications_token_list()
  2. 6.4 notifications.module \notifications_token_list()
  3. 6 notifications.module \notifications_token_list()
  4. 6.2 notifications.module \notifications_token_list()

Implementation of hook_token_list(). Documents the individual tokens handled by the module.

File

./notifications.module, line 1247
Notifications module

Code

function notifications_token_list($type = 'all') {
  $tokens = array();
  if ($type == 'user' || $type == 'all') {
    $tokens['user']['subscriptions-manage'] = t('The url for the current user to manage subscriptions.');
    $tokens['user']['unsubscribe-url'] = t('The url to allow a user to delete all their subscriptions.');
  }
  if ($type == 'subscription' || $type == 'all') {
    $tokens['subscription']['subscription-unsubscribe-url'] = t('The url for disabling a specific subscription.');
  }
  if ($type == 'event' || $type == 'all') {
    $tokens['event']['event-name'] = t('Event name.');
    $tokens['event']['event-user'] = t('Name of the user who caused the event.');
  }

  /*
  if ($type == 'event' || $type == 'all') {
    $tokens['event']['event-list'] = t('List of events for message digests');
    $tokens['event']['event-detail'] = t('Detailed information for event');
  }
  */
  return $tokens;
}