From 20fccf9bf6f8c92f88bb2f905d13d72dffd4231b Mon Sep 17 00:00:00 2001 From: Klaus Leithoff Date: Tue, 5 Feb 2008 15:34:07 +0000 Subject: [PATCH] prepare the date widget to output a very long dateformat (week + dow) --- etemplate/inc/class.date_widget.inc.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/etemplate/inc/class.date_widget.inc.php b/etemplate/inc/class.date_widget.inc.php index 54d2d786ed..04f0d8d7c6 100644 --- a/etemplate/inc/class.date_widget.inc.php +++ b/etemplate/inc/class.date_widget.inc.php @@ -21,7 +21,7 @@ * &8 = dont show time for readonly and type date-time if time is 0:00, * &16 = prefix r/o display with dow * &32 = prefix r/o display with week-number - * + * &48 = prefix r/o display with weeknumber and dow * This widget is independent of the UI as it only uses etemplate-widgets and has therefor no render-function. * Uses the adodb datelibary to overcome the windows-limitation to not allow dates before 1970 * @@ -217,6 +217,10 @@ { $str = lang('Wk').adodb_date('W',adodb_mktime(12,0,0,$value['m'],$value['d'],$value['Y'])).' '; } + if (!$n && $options & 64 ) + { + $str = lang('Wk').adodb_date('W',adodb_mktime(12,0,0,$value['m'],$value['d'],$value['Y'])).' '.lang(adodb_date('l',adodb_mktime(12,0,0,$value['m'],$value['d'],$value['Y']))).' '; + } $str .= ($str != '' ? $sep[$n] : '') . (is_numeric($value[$format[$n]]) ? sprintf('%02d',$value[$format[$n]]) : $value[$format[$n]]); }