summaryrefslogtreecommitdiff
path: root/program/include
diff options
context:
space:
mode:
authorthomascube <thomas@roundcube.net>2011-09-12 19:56:12 +0000
committerthomascube <thomas@roundcube.net>2011-09-12 19:56:12 +0000
commit1cc9e210f5cb340599062ae9cee15cdc9ebd77a7 (patch)
tree7757e25c7e38d9542ca849e4e2c053362854e84d /program/include
parent891b3c13e0ce9e0c56fb47a555f19a7975311748 (diff)
Make date/time format user configurable; drop 'date_today' config option
Diffstat (limited to 'program/include')
-rw-r--r--program/include/main.inc6
1 files changed, 3 insertions, 3 deletions
diff --git a/program/include/main.inc b/program/include/main.inc
index 909d0a5f2..452505f07 100644
--- a/program/include/main.inc
+++ b/program/include/main.inc
@@ -1055,13 +1055,13 @@ function format_date($date, $format=NULL)
// define date format depending on current time
if (!$format) {
if ($CONFIG['prettydate'] && $timestamp > $today_limit && $timestamp < $now) {
- $format = $CONFIG['date_today'] ? $CONFIG['date_today'] : 'H:i';
+ $format = $RCMAIL->config->get('date_today', $RCMAIL->config->get('time_format', 'H:i'));
$today = true;
}
else if ($CONFIG['prettydate'] && $timestamp > $week_limit && $timestamp < $now)
- $format = $CONFIG['date_short'] ? $CONFIG['date_short'] : 'D H:i';
+ $format = $RCMAIL->config->get('date_short', 'D H:i');
else
- $format = $CONFIG['date_long'] ? $CONFIG['date_long'] : 'd.m.Y H:i';
+ $format = $RCMAIL->config->get('date_long', 'Y-m-d H:i');
}
// strftime() format