function date_order_translated in Date 7
Same name and namespace in other branches
- 8 date_api/date_api.module \date_order_translated()
- 5.2 date_api.module \date_order_translated()
- 6.2 date_api.module \date_order_translated()
- 7.3 date_api/date_api.module \date_order_translated()
- 7.2 date_api/date_api.module \date_order_translated()
Helper function for BYDAY options in Date Repeat and for converting back and forth from '+1' to 'First' .
1 call to date_order_translated()
- date_repeat_dow_count_options in date_repeat/
date_repeat.module - Helper function for BYDAY options.
File
- date_api/
date_api.module, line 1801 - This module will make the date API available to other modules. Designed to provide a light but flexible assortment of functions and constants, with more functionality in additional files that are not loaded unless other modules specifically include them.
Code
function date_order_translated() {
return array(
'+1' => t('First', array(), array(
'context' => 'date_order',
)),
'+2' => t('Second', array(), array(
'context' => 'date_order',
)),
'+3' => t('Third', array(), array(
'context' => 'date_order',
)),
'+4' => t('Fourth', array(), array(
'context' => 'date_order',
)),
'+5' => t('Fifth', array(), array(
'context' => 'date_order',
)),
'-1' => t('Last', array(), array(
'context' => 'date_order_reverse',
)),
'-2' => t('Next to last', array(), array(
'context' => 'date_order_reverse',
)),
'-3' => t('Third from last', array(), array(
'context' => 'date_order_reverse',
)),
'-4' => t('Fourth from last', array(), array(
'context' => 'date_order_reverse',
)),
'-5' => t('Fifth from last', array(), array(
'context' => 'date_order_reverse',
)),
);
}