aboutsummaryrefslogtreecommitdiffstats
path: root/print.php
diff options
context:
space:
mode:
authorChad Little <clittle@users.sourceforge.net>2002-10-27 02:34:32 +0000
committerChad Little <clittle@users.sourceforge.net>2002-10-27 02:34:32 +0000
commit0ea6ec6e0653a11059394d38ee75e300abe32759 (patch)
tree563d2c83dcb031ecb821ed7fe65839b67f7fd756 /print.php
parent8bbbdd3905e6d788fe6893acebc3dad8029f1470 (diff)
downloadphpicalendar-0ea6ec6e0653a11059394d38ee75e300abe32759.tar.gz
phpicalendar-0ea6ec6e0653a11059394d38ee75e300abe32759.tar.bz2
phpicalendar-0ea6ec6e0653a11059394d38ee75e300abe32759.zip
printer view check in.
Diffstat (limited to 'print.php')
-rw-r--r--print.php114
1 files changed, 114 insertions, 0 deletions
diff --git a/print.php b/print.php
new file mode 100644
index 0000000..8c0e504
--- /dev/null
+++ b/print.php
@@ -0,0 +1,114 @@
+<?php
+
+define('BASE', './');
+include(BASE.'functions/ical_parser.php');
+$cal_displayname2 = $calendar_name . " $calendar_lang";
+if (strlen($cal_displayname2) > 24) {
+ $cal_displayname2 = substr("$cal_displayname2", 0, 21);
+ $cal_displayname2 = $cal_displayname2 . "...";
+}
+
+$start_week_time = strtotime(dateOfWeek($getdate, $week_start_day));
+$end_week_time = $start_week_time + (6 * 25 * 60 * 60);
+$start_week = localizeDate($dateFormat_week, $start_week_time);
+$end_week = localizeDate($dateFormat_week, $end_week_time);
+$parse_month = date ("Ym", strtotime($getdate));
+$rssview = $HTTP_GET_VARS['rssview'];
+$cal_displayname = str_replace("32", " ", $cal);
+$events_week = 0;
+
+ ?>
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
+ "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">
+<html>
+<head>
+ <meta http-equiv="content-type" content="text/html;charset=UTF-8">
+ <title><?php echo "$goprint_lang"; ?></title>
+ <link rel="stylesheet" type="text/css" href="styles/<?php echo $style_sheet.'/default.css'; ?>">
+</head>
+<body bgcolor="#FFFFFF">
+<center><table border="0" width="737" cellspacing="0" cellpadding="0" bgcolor="#FFFFFF" class="calborder">
+ <tr>
+ <td align="left" valign="top" width="1%" class="sideback"><?php echo "<img src=\"images/spacer.gif\" alt=\"right\" height=\"22\" border=\"0\" align=\"left\">"; ?></td>
+ <td align="center" width="98%" class="sideback"><font class="G10BOLD"><?php print (localizeDate ($dateFormat_day, strtotime($getdate))); ?></font></td>
+ <td align="right" valign="top" width="1%" class="sideback"></td>
+ </tr>
+ <tr>
+ <td colspan="3"><img src="images/spacer.gif" width="1" height="5"></td>
+ </tr>
+ <tr>
+ <td colspan="3">
+ <table border="0" cellspacing="0" cellpadding="0" width="100%">
+ <tr>
+ <td align="center" valign="top">
+ <table width="100%" border="0" cellspacing="0" cellpadding="0">
+ <tr>
+ <td colspan="3" height="1"></td>
+ </tr>
+ <?php
+ // Iterate the entire master array
+ foreach($master_array as $key => $val) {
+
+ // Pull out only this months
+ ereg ("([0-9]{6})([0-9]{2})", $key, $regs);
+ if ($regs[1] == $parse_month) {
+ $dayofmonth = strtotime ($key);
+ $dayofmonth = localizeDate ($dateFormat_day, $dayofmonth);
+ echo "<tr><td width=\"10\"><img src=\"images/spacer.gif\" width=\"10\" height=\"1\"></td>\n";
+ echo "<td colspan=\"2\"><font class=\"V12\"><b>$dayofmonth</b></font></td></tr>";
+ echo "<tr><td colspan=\"3\"><img src=\"images/spacer.gif\" width=\"1\" height=\"5\"></td></tr>\n";
+
+ // Pull out each day
+ foreach ($val as $new_val) {
+
+ // Pull out each time
+ foreach ($new_val as $new_key2 => $new_val2) {
+ if ($new_val2["event_text"]) {
+ $event_text = stripslashes(urldecode($new_val2["event_text"]));
+ $description = stripslashes(urldecode($new_val2["description"]));
+ $event_start = $new_val2["event_start"];
+ $event_end = $new_val2["event_end"];
+ $event_start = date ($timeFormat, strtotime ("$event_start"));
+ $event_end = date ($timeFormat, strtotime ("$event_end"));
+ if (!$new_val2["event_start"]) {
+ $event_start = "$all_day_lang";
+ $event_start2 = '';
+ $event_end = '';
+ }
+ echo "<tr>\n";
+ echo "<td width=\"10\"><img src=\"images/spacer.gif\" width=\"10\" height=\"1\"></td>\n";
+ echo "<td width=\"10\"><img src=\"images/spacer.gif\" width=\"10\" height=\"1\"></td>\n";
+ echo "<td align=\"left\">\n";
+ echo "<table width=\"100%\" border=\"0\" cellspacing=\"1\" cellpadding=\"1\">\n";
+ echo "<tr>\n";
+ echo "<td width=\"100\" class=\"G10BOLD\">Time:</td>\n";
+ echo "<td align=\"left\" class=\"G10B\">$event_start - $event_end</td>\n";
+ echo "</tr>\n";
+ echo "<tr>\n";
+ echo "<td valign=\"top\" width=\"100\" class=\"G10BOLD\">Summary:</td>\n";
+ echo "<td valign=\"top\" align=\"left\" class=\"G10B\">$event_text</td>\n";
+ echo "</tr>\n";
+ if ($new_val2["description"]) {
+ echo "<tr>\n";
+ echo "<td valign=\"top\" width=\"100\" class=\"G10BOLD\">Description:</td>\n";
+ echo "<td valign=\"top\" align=\"left\" class=\"G10B\">$description</td>\n";
+ echo "</tr>\n";
+ }
+ echo "</table>\n";
+ echo "</td>\n";
+ echo "</tr>\n";
+ echo "<tr><td colspan=\"3\"><img src=\"images/spacer.gif\" width=\"1\" height=\"10\"></td></tr>\n";
+ }
+ }
+ }
+ }
+ }
+
+ ?>
+ </table>
+ </td>
+ </tr>
+ </table>
+ </td>
+ </tr>
+</table>

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