From: <ji...@us...> - 2008-12-25 18:45:31
|
Update of /cvsroot/phpicalendar/phpicalendar/functions/parse In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv28460/functions/parse Modified Files: end_vevent.php recur_functions.php Log Message: progress on timezones and daylight time Index: end_vevent.php =================================================================== RCS file: /cvsroot/phpicalendar/phpicalendar/functions/parse/end_vevent.php,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** end_vevent.php 24 Dec 2008 09:54:28 -0000 1.12 --- end_vevent.php 25 Dec 2008 18:45:26 -0000 1.13 *************** *** 321,325 **** $start_unixtime_tmp = mktime($recur_data_hour,$recur_data_minute,0,$recur_data_month,$recur_data_day,$recur_data_year); $end_unixtime_tmp = $start_unixtime_tmp + $length; - if (($end_time >= $phpiCal_config->bleed_time) && ($bleed_check == '-1')) { $start_tmp = strtotime(date('Ymd',$start_unixtime_tmp)); --- 321,324 ---- *************** *** 340,388 **** $display_end_tmp = $end_time; } ! ! // Let's double check the until to not write past it ! $until_check = $start_date_tmp.$time_tmp.'00'; ! if (@$until > $until_check) { ! $master_array[$start_date_tmp][$time_tmp][$uid] = array ( ! 'event_start' => $start_time_tmp, ! 'event_end' => $end_time_tmp, ! 'start_unixtime' => $start_unixtime_tmp, ! 'end_unixtime' => $end_unixtime_tmp, ! 'event_text' => $summary, ! 'event_length' => $length, ! 'event_overlap' => 0, ! 'description' => $description, ! 'status' => $status, ! 'class' => $class, ! 'spans_day' => true, ! 'location' => $location, ! 'organizer' => serialize($organizer), ! 'attendee' => serialize($attendee), ! 'calnumber' => $calnumber, ! 'calname' => $actual_calname, ! 'url' => $url, ! 'recur' => $recur); ! if (isset($display_end_tmp)){ ! $master_array[$start_date_tmp][$time_tmp][$uid]['display_end'] = $display_end_tmp; ! } ! checkOverlap($start_date_tmp, $time_tmp, $uid); ! } ! $start_tmp = strtotime('+1 day',$start_tmp); ! } ! } else { ! if ($bleed_check == '-1') { ! $display_end_tmp = $end_time; ! $end_time_tmp1 = '2400'; ! ! } ! if (!isset($end_time_tmp1)) $end_time_tmp1 = $end_time; ! ! // Let's double check the until to not write past it ! $master_array[($recur_data_date)][($hour.$minute)][$uid] = array ( ! 'event_start' => $start_time, ! 'event_end' => $end_time_tmp1, 'start_unixtime' => $start_unixtime_tmp, 'end_unixtime' => $end_unixtime_tmp, ! 'event_text' => $summary, 'event_length' => $length, 'event_overlap' => 0, --- 339,348 ---- $display_end_tmp = $end_time; } ! $master_array[$start_date_tmp][$time_tmp][$uid] = array ( ! 'event_start' => $start_time_tmp, ! 'event_end' => $end_time_tmp, 'start_unixtime' => $start_unixtime_tmp, 'end_unixtime' => $end_unixtime_tmp, ! 'event_text' => $summary, # 'event_length' => $length, 'event_overlap' => 0, *************** *** 390,394 **** 'status' => $status, 'class' => $class, ! 'spans_day' => false, 'location' => $location, 'organizer' => serialize($organizer), --- 350,354 ---- 'status' => $status, 'class' => $class, ! 'spans_day' => true, 'location' => $location, 'organizer' => serialize($organizer), *************** *** 399,405 **** 'recur' => $recur); if (isset($display_end_tmp)){ ! $master_array[($recur_data_date)][($hour.$minute)][$uid]['display_end'] = $display_end_tmp; } ! checkOverlap($recur_data_date, ($hour.$minute), $uid); } --- 359,397 ---- 'recur' => $recur); if (isset($display_end_tmp)){ ! $master_array[$start_date_tmp][$time_tmp][$uid]['display_end'] = $display_end_tmp; } ! checkOverlap($start_date_tmp, $time_tmp, $uid); ! $start_tmp = strtotime('+1 day',$start_tmp); ! } ! } else { ! if ($bleed_check == '-1') { ! $display_end_tmp = $end_time; ! $end_time_tmp1 = '2400'; ! ! } ! if (!isset($end_time_tmp1)) $end_time_tmp1 = $end_time; ! $master_array[($recur_data_date)][($hour.$minute)][$uid] = array ( ! 'event_start' => $start_time, ! 'event_end' => $end_time_tmp1, ! 'start_unixtime' => $start_unixtime_tmp, ! 'end_unixtime' => $end_unixtime_tmp, ! 'event_text' => $summary, ! 'event_length' => $length, ! 'event_overlap' => 0, ! 'description' => $description, ! 'status' => $status, ! 'class' => $class, ! 'spans_day' => false, ! 'location' => $location, ! 'organizer' => serialize($organizer), ! 'attendee' => serialize($attendee), ! 'calnumber' => $calnumber, ! 'calname' => $actual_calname, ! 'url' => $url, ! 'recur' => $recur); ! if (isset($display_end_tmp)){ ! $master_array[($recur_data_date)][($hour.$minute)][$uid]['display_end'] = $display_end_tmp; ! } ! checkOverlap($recur_data_date, ($hour.$minute), $uid); } Index: recur_functions.php =================================================================== RCS file: /cvsroot/phpicalendar/phpicalendar/functions/parse/recur_functions.php,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** recur_functions.php 24 Dec 2008 21:09:31 -0000 1.10 --- recur_functions.php 25 Dec 2008 18:45:26 -0000 1.11 *************** *** 29,32 **** --- 29,33 ---- /*BYMONTH, BYWEEKNO, BYYEARDAY, BYMONTHDAY, BYDAY, BYHOUR, BYMINUTE, BYSECOND and BYSETPOS*/ + #dump_times($times); $times = restrict_bymonth($times,$freq); # $times = restrict_byweekno($times,$freq); *************** *** 254,258 **** echo "<pre>$summary times:"; #var_dump($times); ! foreach($times as $time) echo "\ndate:".date("Ymd his",$time); echo "</pre>"; } --- 255,259 ---- echo "<pre>$summary times:"; #var_dump($times); ! foreach($times as $time) echo "\ndate:".date("Y-m-d H:i:s",$time); echo "</pre>"; } |