aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChad Little <clittle@users.sourceforge.net>2002-11-22 04:40:34 +0000
committerChad Little <clittle@users.sourceforge.net>2002-11-22 04:40:34 +0000
commite8f599570c9223ae7c875ad1a73bd1c157a5a5c3 (patch)
treeb0fb18548d56fe9a7b16fb2d9c4ccd9afa681c65
parent65669516eee7b3775725279c458a115fb771d3b3 (diff)
downloadphpicalendar-e8f599570c9223ae7c875ad1a73bd1c157a5a5c3.zip
phpicalendar-e8f599570c9223ae7c875ad1a73bd1c157a5a5c3.tar.gz
phpicalendar-e8f599570c9223ae7c875ad1a73bd1c157a5a5c3.tar.bz2
Todo image inclusion
-rw-r--r--functions/ical_parser.php30
-rw-r--r--images/completed.gifbin0 -> 75 bytes
-rw-r--r--images/important.gifbin0 -> 125 bytes
-rw-r--r--images/not_completed.gifbin0 -> 73 bytes
-rw-r--r--sidebar.php6
5 files changed, 20 insertions, 16 deletions
diff --git a/functions/ical_parser.php b/functions/ical_parser.php
index b4bdd0f..829d5d2 100644
--- a/functions/ical_parser.php
+++ b/functions/ical_parser.php
@@ -168,9 +168,9 @@ if ($parse_file) {
// handle single changes in recurring events
// Maybe this is no longer need since done at bottom of parser? - CL 11/20/02
- if ($uid_valid && $write_processed) {
- $processed[$uid] = array($start_date,($hour.$minute));
- }
+ //if ($uid_valid && $write_processed) {
+ // $processed[$uid] = array($start_date,($hour.$minute));
+ //}
// Handling of the all day events
if ((isset($allday_start) && $allday_start != '')) {
@@ -810,33 +810,35 @@ if ($parse_file) {
}
}
}
-
+//print '<pre>';
// Remove pesky recurrences
+ unset ($key, $val);
foreach ($recurrence_delete as $delete => $delete_key) {
foreach ($delete_key as $key => $val) {
+ echo "Before Delete:: $delete $key $val<br>";
+ #print_r($master_array["$delete"]);
if (is_array($master_array[($delete)][($key)][($val)])) {
unset($master_array["$delete"]["$key"]["$val"]);
// Remove date from array if no events
if (sizeof($master_array["$delete"]["$key"] = 1)) {
- #echo "deleting $delete $key $val<br>";
+ echo "deleting $delete $key $val<br>";
unset($master_array["$delete"]["$key"]);
if (!sizeof($master_array["$delete"] > 1)) {
- #echo "deleting $delete $key $val<br>";
+ echo "deleting $delete $key $val<br>";
unset($master_array["$delete"]);
}
}
- // print_r($master_array["$delete"]);
+ print_r($master_array["$delete"]);
// Check for overlaps and rewrite them
foreach($master_array["$delete"] as $overlap_time => $overlap_val) {
$recur_data_date = $delete;
foreach ($overlap_val as $uid => $val) {
$start_time = $val['event_start'];
$end_time = $val['event_end'];
- reset($master_array);
#$nbrOfOverlaps = checkOverlap($recur_data_date, $start_time, $end_time);
- $master_array[($recur_data_date)][($start_time)][($uid)]['event_overlap'] = $nbrOfOverlaps;
- #echo "$recur_data_date - $uid - $start_time - $end_time - $nbrOfOverlaps<br>";
- #print_r($val);
+ $master_array[($recur_data_date)][($start_time)][($uid)]['event_overlap'] = 0;
+ echo "$recur_data_date - $uid - $start_time - $end_time - $nbrOfOverlaps<br>";
+ print_r($val);
}
}
}
@@ -869,13 +871,13 @@ if ($parse_file) {
//If you want to see the values in the arrays, uncomment below.
-//print '<pre>';
-//print_r($master_array);
+print '<pre>';
+print_r($master_array);
//print_r($overlap_array);
//print_r($day_array);
//print_r($rrule);
//print_r($recurrence_delete);
-//print '</pre>';
+print '</pre>';
?>
diff --git a/images/completed.gif b/images/completed.gif
new file mode 100644
index 0000000..aae0ba1
--- /dev/null
+++ b/images/completed.gif
Binary files differ
diff --git a/images/important.gif b/images/important.gif
new file mode 100644
index 0000000..784b136
--- /dev/null
+++ b/images/important.gif
Binary files differ
diff --git a/images/not_completed.gif b/images/not_completed.gif
new file mode 100644
index 0000000..3a96b28
--- /dev/null
+++ b/images/not_completed.gif
Binary files differ
diff --git a/sidebar.php b/sidebar.php
index 06b701f..34e93be 100644
--- a/sidebar.php
+++ b/sidebar.php
@@ -230,10 +230,12 @@ if ((isset($master_array['-2'])) && ($show_todos == 'yes')) { ?>
if ($val['status'] == 'COMPLETED') {
if ($show_completed == 'yes') {
$event_text = "<S>$event_text</S>";
- echo "<a class=\"psf\" href=\"javascript:openEventInfo('$event_text2', '$calendar_name2', '$event_start', '$event_end', '$description')\"><font class=\"G10B\">&#149; $event_text</font></a><br>\n";
+ echo "<a class=\"psf\" href=\"javascript:openEventInfo('$event_text2', '$calendar_name2', '$event_start', '$event_end', '$description')\"><font class=\"G10B\"><img src=\"images/completed.gif\" alt=\"\" width=\"13\" height=\"11\" border=\"0\" align=\"middle\"> $event_text</font></a><br>\n";
}
+ } elseif ($val['priority'] > 0) {
+ echo "<a class=\"psf\" href=\"javascript:openEventInfo('$event_text2', '$calendar_name2', '$event_start', '$event_end', '$description')\"><font class=\"G10B\"><img src=\"images/important.gif\" alt=\"\" width=\"13\" height=\"11\" border=\"0\" align=\"middle\"> $event_text</font></a><br>\n";
} else {
- echo "<a class=\"psf\" href=\"javascript:openEventInfo('$event_text2', '$calendar_name2', '$event_start', '$event_end', '$description')\"><font class=\"G10B\">&#149; $event_text</font></a><br>\n";
+ echo "<a class=\"psf\" href=\"javascript:openEventInfo('$event_text2', '$calendar_name2', '$event_start', '$event_end', '$description')\"><font class=\"G10B\"><img src=\"images/not_completed.gif\" alt=\"\" width=\"13\" height=\"11\" border=\"0\" align=\"middle\"> $event_text</font></a><br>\n";
}
}
}

© 2014-2020 Faster IT GmbH | imprint | privacy policy