aboutsummaryrefslogtreecommitdiffstats
path: root/month.php
diff options
context:
space:
mode:
authorjwangen <jwangen>2002-10-04 09:32:29 +0000
committerjwangen <jwangen>2002-10-04 09:32:29 +0000
commitce4d8be46ccefe642883253544a4ec81bdde8cc5 (patch)
tree90b62a3a91556bcbb348ae3e3f1ba8acbc494251 /month.php
parent9d2eafe2e806a86b5617ed98040fd8667066f852 (diff)
downloadphpicalendar-ce4d8be46ccefe642883253544a4ec81bdde8cc5.tar.gz
phpicalendar-ce4d8be46ccefe642883253544a4ec81bdde8cc5.tar.bz2
phpicalendar-ce4d8be46ccefe642883253544a4ec81bdde8cc5.zip
Fixed almost all the warning we were getting before. Basically just added
isset() to all the conditions that were reporting errors. One line in ical_parser needs to be double checked, it's commented, towards the bottom.
Diffstat (limited to 'month.php')
-rw-r--r--month.php16
1 files changed, 9 insertions, 7 deletions
diff --git a/month.php b/month.php
index e3b7335..c6ddf25 100644
--- a/month.php
+++ b/month.php
@@ -21,7 +21,7 @@
$display_month = localizeDate ($dateFormat_month, $date);
$parse_month = date ("Ym", $date);
$first_of_month = $this_year.$this_month."01";
- $start_month_day = dateOfWeek($first_of_month, $start_week_day);
+ $start_month_day = dateOfWeek($first_of_month, $week_start_day);
$thisday2 = localizeDate($dateFormat_week_list, $unix_time);
@@ -119,7 +119,7 @@
}
}
if ($i == 0) echo "<tr height=\"105\">\n";
- if (($master_array[("$daylink")]) && ($check_month == $this_month)) {
+ if (isset($master_array[("$daylink")]) && ($check_month == $this_month)) {
echo "<td align=\"center\" valign=\"top\" bgcolor=\"$bgcolor\" width=\"105\" height=\"105\">\n";
echo "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"1\">\n";
echo "<tr>\n";
@@ -137,10 +137,10 @@
$event_text2 = urlencode($event_text2);
$description = addslashes($val["description"]);
$description = urlencode($description);
- $event_start = $val["event_start"];
- $event_end = $val["event_end"];
- $event_start = date ($timeFormat, strtotime ("$event_start"));
- $event_end = date ($timeFormat, strtotime ("$event_end"));
+ $event_start = @$val["event_start"];
+ $event_end = @$val["event_end"];
+ $event_start = date ($timeFormat, @strtotime ("$event_start"));
+ $event_end = date ($timeFormat, @strtotime ("$event_end"));
$calendar_name2 = addslashes($calendar_name);
$calendar_name2 = urlencode($calendar_name2);
if (strlen($event_text) > 12) {
@@ -152,7 +152,9 @@
echo "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">\n";
echo "<tr>\n";
echo "<td>\n";
- if (!$event_start == $val["event_start"]) {
+ if (!isset($val["event_start"])) {
+ $event_start = 'All';
+ $event_end = 'Day';
echo "<center><a class=\"psf\" href=\"javascript:openEventInfo('$event_text2', '$calendar_name2', '$event_start', '$event_end', '$description')\"><i>$event_text</i></a></center>\n";
} else {
echo "<a class=\"psf\" href=\"javascript:openEventInfo('$event_text2', '$calendar_name2', '$event_start', '$event_end', '$description')\"><font class=\"G10B\">&#149; $event_text</a>\n";

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