From 1b4972583022025694d44266c56e64160d309816 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Sun, 9 Mar 2003 21:05:29 +0000 Subject: [PATCH] fix for gnu-bug #136: dates in week-selectbox are (sometimes) wrong, the endate of a week is the same as the startdate of the next one This is caused by changes in daylight saveing and useing midnight for the calculation, changed it to midday --- calendar/inc/class.uicalendar.inc.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/calendar/inc/class.uicalendar.inc.php b/calendar/inc/class.uicalendar.inc.php index 97cea7119f..c1bee4eebf 100755 --- a/calendar/inc/class.uicalendar.inc.php +++ b/calendar/inc/class.uicalendar.inc.php @@ -2612,8 +2612,9 @@ $str = ''; for ($i = -7; $i <= 7; $i++) { - $begin = $sun + (604800 * $i); - $end = $begin + 604799; + $begin = $sun + (7*24*60*60 * $i) + 12*60*60; // we use midday, that changes in daylight-saveing does not effect us + $end = $begin + 6*24*60*60; +// echo "
$i: ".date('d.m.Y H:i',$begin).' - '.date('d.m.Y H:i',$end); $str .= '