function clock_token_info in Clock 7.2
Implements hook_token_info()
File
- ./
clock.tokens.inc, line 11 - Token-related functions for Clock module.
Code
function clock_token_info() {
$info = array(
'types' => array(
'clock' => array(
'name' => t('Clock'),
'description' => t('Tokens related to the display of clocks.'),
'needs-data' => 'clock',
),
'time-zone' => array(
'name' => t('Time zone'),
'description' => t('Tokens related to a certain time zone'),
'needs-data' => 'time-zone',
),
),
'tokens' => array(
'clock' => array(
'date' => array(
'name' => t('Date'),
'description' => t('The current date of the clock in the correct time zone and format.'),
),
'time-zone' => array(
'name' => t('Time zone'),
'description' => t('The time zone of the clock.'),
'type' => 'time-zone',
),
'date-type' => array(
'name' => t('Date type'),
'description' => t('The date type of the clock.'),
),
'cid' => array(
'name' => t('Clock ID'),
'description' => t('A unique identifier for this clock.'),
),
),
'time-zone' => array(
'name' => array(
'name' => t('Name'),
'description' => t('The complete name of the time zone, e.g. America/New York or UTC.'),
),
'contintent' => array(
'name' => t('Continent'),
'description' => t('The continent part of the time zone, e.g. America.'),
),
'city' => array(
'name' => t('City'),
'description' => t('The city part of the time zone, e.g. New York.'),
),
'offset' => array(
'name' => t('Offset'),
'description' => t('The offset of the time zone respective UTC in seconds.'),
),
'offset-name' => array(
'name' => t('Offset name'),
'description' => t('The name of the offset, e.g. EDT or UTC'),
),
'daylight-savings-time' => array(
'name' => t('Daylight savings time marker'),
'description' => t('A marker (!marker) in case the time zone is currently in daylight savings time.', array(
'!marker' => theme('clock_daylight_savings_time_marker'),
)),
),
),
),
);
return $info;
}