From: <cl...@us...> - 2003-05-29 05:28:40
|
Update of /cvsroot/phpicalendar/phpicalendar In directory sc8-pr-cvs1:/tmp/cvs-serv7346 Modified Files: month.php Log Message: Month.php now does new javascript popups. Index: month.php =================================================================== RCS file: /cvsroot/phpicalendar/phpicalendar/month.php,v retrieving revision 1.87 retrieving revision 1.88 diff -C2 -d -r1.87 -r1.88 *** month.php 9 May 2003 20:28:56 -0000 1.87 --- month.php 29 May 2003 05:28:36 -0000 1.88 *************** *** 58,62 **** } ?> - <?php include (BASE.'functions/event.js'); ?> </head> <body> --- 58,61 ---- *************** *** 158,193 **** foreach ($event_times as $val) { $num_of_events++; ! $event_text = stripslashes(urldecode($val["event_text"])); ! $event_text = strip_tags($event_text, '<b><i><u>'); ! if ($event_text != "") { ! $event_text2 = addslashes($val["event_text"]); ! $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_start2 = date ($timeFormat_small, @strtotime ("$event_start")); ! $event_end = date ($timeFormat, @strtotime ("$event_end")); ! $calendar_name2 = addslashes($calendar_name); ! $calendar_name2 = urlencode($calendar_name2); ! $event_text = word_wrap($event_text, 12, $month_event_lines); ! $status = $val["status"]; ! echo "<tr>\n"; ! echo "<td>\n"; ! echo "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">\n"; ! echo "<tr>\n"; ! if (!isset($val["event_start"])) { ! $event_start = ''; ! $event_end = ''; ! echo "<td><font class=\"V10\"><center><a class=\"psf\" href=\"javascript:openEventInfo('$event_text2', '$calendar_name2', '$event_start', '$event_end', '$description', '$status')\"><i>$event_text</i></a></center></font></td>\n"; ! } else { ! echo "<td align=\"left\" valign=\"top\"><a class=\"psf\" href=\"javascript:openEventInfo('$event_text2', '$calendar_name2', '$event_start', '$event_end', '$description', '$status')\"><font class=\"V9\"> $event_start2 $event_text</font></a></td>\n"; ! } ! echo "</tr>\n"; ! echo "</table>\n"; ! echo "</td>\n"; ! echo "</tr>\n"; } } } --- 157,187 ---- foreach ($event_times as $val) { $num_of_events++; ! echo "<tr><td>\n"; ! echo "<table width=\"100%\" cellspacing=\"0\" cellpadding=\"0\">"; ! echo "<tr>\n"; ! if (!isset($val["event_start"])) { ! echo "<td align=center>"; ! openevent("$calendar_name", "", "", $val, ! "<font class=\"V10\"><i>", ! "</i></font>"); ! } else { ! $event_start = @$val["event_start"]; ! $event_end = @$val["event_end"]; ! $event_start = date($timeFormat, @strtotime ("$event_start")); ! $start2 = date($timeFormat_small,@strtotime("$event_start")); ! $event_end = date($timeFormat, @strtotime ("$event_end")); ! echo "<td align=\"left\" valign=\"top\">"; ! openevent("$calendar_name", ! "$event_start", ! "$event_end", ! $val, ! $month_event_lines, ! 12, ! "<font class=\"V9\"> $start2 ", ! "</font>"); } + echo "</td></tr>\n"; + echo "</table>\n"; + echo "</td></tr>\n"; } } *************** *** 257,267 **** foreach ($new_val as $new_key2 => $new_val2) { if ($new_val2["event_text"]) { - $event_text = stripslashes(urldecode($new_val2["event_text"])); - $event_text2 = addslashes($new_val2["event_text"]); - $event_text2 = str_replace("\"", """, $event_text2); - $event_text2 = urlencode($event_text2); - $description = addslashes(urlencode($new_val2["description"])); - $description = str_replace("\"", """, $description); - $status = $new_val2["status"]; if (isset($new_val2["event_start"])) { $event_start = $new_val2["event_start"]; --- 251,254 ---- *************** *** 269,287 **** $event_start = date ($timeFormat, strtotime ("$event_start")); $event_end = date ($timeFormat, strtotime ("$event_end")); - $event_text = str_replace ("<br>", "", $event_text); $event_start2 = $event_start; } else { $event_start = "$all_day_lang"; $event_start2 = ''; ! $event_end = ''; } ! if (strlen($event_text) > 70) { ! $event_text = substr("$event_text", 0, 65); ! $event_text = $event_text . "..."; } ! echo "<tr>\n"; echo "<td align=\"left\" valign=\"top\" width =\"160\" class=\"montheventline\" nowrap><font $fontclass> <a class=\"psf\" href=\"day.php?cal=$cal&getdate=$key\">$dayofmonth</a></font> <font class=\"V9G\">($event_start)</font></td>\n"; echo "<td align=\"left\" valign=\"top\" colspan=\"2\">\n"; ! echo " <a class=\"psf\" href=\"javascript:openEventInfo('$event_text2', '$calendar_name', '$event_start2', '$event_end', '$description', '$status')\"><font class=\"G10B\">$event_text</font></a>\n"; echo "</td>\n"; echo "</tr>\n"; --- 256,278 ---- $event_start = date ($timeFormat, strtotime ("$event_start")); $event_end = date ($timeFormat, strtotime ("$event_end")); $event_start2 = $event_start; } else { $event_start = "$all_day_lang"; $event_start2 = ''; ! $event_end = ''; } ! echo "<tr>\n"; echo "<td align=\"left\" valign=\"top\" width =\"160\" class=\"montheventline\" nowrap><font $fontclass> <a class=\"psf\" href=\"day.php?cal=$cal&getdate=$key\">$dayofmonth</a></font> <font class=\"V9G\">($event_start)</font></td>\n"; echo "<td align=\"left\" valign=\"top\" colspan=\"2\">\n"; ! openevent("$calendar_name", ! "$event_start", ! "$event_end", ! $new_val2, ! 0, ! 65, ! "<font class=\"G10B\"> ", ! "</font>"); ! //echo " <a class=\"psf\" href=\"javascript:openEventInfo('$event_text2', '$calendar_name', '$event_start2', '$event_end', '$description', '$status')\"><font class=\"G10B\">$event_text</font></a>\n"; echo "</td>\n"; echo "</tr>\n"; |