summaryrefslogtreecommitdiff
path: root/forum/utils
diff options
context:
space:
mode:
Diffstat (limited to 'forum/utils')
-rw-r--r--forum/utils/calendar.php16
1 files changed, 16 insertions, 0 deletions
diff --git a/forum/utils/calendar.php b/forum/utils/calendar.php
index 006922c..318f458 100644
--- a/forum/utils/calendar.php
+++ b/forum/utils/calendar.php
@@ -23,6 +23,22 @@ if($action=="addentry") {
if($ZEND_DIR != "") googleCalendarEvent($event);
+ if($DOKUWIKI_CALENDAR != "") {
+ $file = $DOKUWIKI_CALENDAR;
+ $fp = fopen($file, "w");
+
+ fprintf($fp, "=====DIEs calendar=====\n");
+ fprintf($fp, "Do not edit this file - it is automatically generated by the ExecutionRoom CMS.\n\n");
+ fprintf($fp, "====Events====\n");
+ foreach($events->events as $event) {
+ fprintf($fp, " * %s - %s %s: %s\n",
+ date("j.n.Y G:i", $event->starttime),
+ date("j.n.Y G:i", $event->starttime + $event->duration),
+ $event->title, $event->description);
+ }
+ fclose($fp);
+ }
+
notify("calendar", "New calendar entry:\n" . $title . "\n" . date("r", $time) . "\n" .
$description . "\n" .
$FORUM_URL . "/?mode=calendar&date=" . $time);