You are here

function registration_token_info in Entity Registration 8

Same name and namespace in other branches
  1. 8.2 registration.module \registration_token_info()
  2. 7.2 registration.module \registration_token_info()
  3. 7 registration.module \registration_token_info()

Implement hook_token_info().

File

./registration.module, line 1324

Code

function registration_token_info() {
  $type = array(
    'name' => t('Registration'),
    'description' => t('Tokens related to individual Registrations.'),
    'needs-data' => 'registration',
  );
  $registration['entity'] = array(
    'name' => t("Registration Host Entity"),
    'description' => t("The host entity for the registration."),
  );
  $registration['user'] = array(
    'name' => t("Registration User"),
    'description' => t("The user the registration is for."),
    'type' => 'user',
  );
  return array(
    'types' => array(
      'registration' => $type,
    ),
    'tokens' => array(
      'registration' => $registration,
    ),
  );
}