function bat_date_formats in Booking and Availability Management Tools for Drupal 7
Implements hook_date_formats().
File
- ./
bat.module, line 121 - Provides basic underlying functionality and configuration options used by all BAT modules.
Code
function bat_date_formats() {
$formats = array();
$formats[] = array(
'type' => 'bat_daily',
'format' => variable_get('bat_daily_date_format', 'Y-m-d'),
'locales' => array(),
);
$formats[] = array(
'type' => 'bat',
'format' => variable_get('bat_date_format', 'Y-m-d H:i'),
'locales' => array(),
);
foreach ($formats as $format) {
variable_set('date_format_' . $format['type'], $format['format']);
}
return $formats;
}