You are here

function scald_token_info in Scald: Media Management made easy 7

Implements hook_token_info().

File

./scald.tokens.inc, line 11
Builds placeholder replacement tokens for atom-related data.

Code

function scald_token_info() {
  $type = array(
    'name' => t('Atoms'),
    'description' => t('Tokens related to atoms.'),
    'needs-data' => 'atom',
  );
  $atom['title'] = array(
    'name' => t('Title'),
    'description' => t('The title of the atom.'),
  );
  $atom['author'] = array(
    'name' => t('Author'),
    'description' => t('The author, or publisher if there is no author, of the atom.'),
  );
  return array(
    'types' => array(
      'atom' => $type,
    ),
    'tokens' => array(
      'atom' => $atom,
    ),
  );
}