summaryrefslogtreecommitdiff
path: root/inc/ical.php
diff options
context:
space:
mode:
authorHorus2021-01-14 12:15:03 +0100
committerHorus2021-01-14 12:15:03 +0100
commit20ed3c2e6dbc417dc0fede674894457ac6231410 (patch)
tree7d3af6abfee17bee4f291c1c0d597c9d690a3439 /inc/ical.php
parent983167172a7995acc86c6bd05ea4c268845f1ffe (diff)
downloadzeitumstellung-20ed3c2e6dbc417dc0fede674894457ac6231410.tar.gz
Fix php warning.
Diffstat (limited to 'inc/ical.php')
-rw-r--r--inc/ical.php39
1 files changed, 0 insertions, 39 deletions
diff --git a/inc/ical.php b/inc/ical.php
deleted file mode 100644
index 7cc30e9..0000000
--- a/inc/ical.php
+++ /dev/null
@@ -1,39 +0,0 @@
-<?php
-require_once __DIR__ . '/../vendor/autoload.php';
-
-use Eluceo\iCal\Component\Calendar;
-use Eluceo\iCal\Component\Event;
-
-function iCalFeed() {
-
- $vCalendar = new Calendar(APP_BASE);
- $vCalendar->setName(APP_NAME);
- $vCalendar->setTimezone('Europe/Berlin');
-
- $tc = new Zeitumstellung();
-
- for ( $i=0; $i<3; $i++ ) {
-
- $vEvent = new Event();
- $vEvent
- ->setDtStart(new \DateTime($tc->dateText))
- ->setDtEnd(new \DateTime($tc->dateText))
- ->setNoTime(true)
- ->setSummary('Zeitumstellung')
- ->setUrl( APP_URL )
- ->setDescription($tc->description)
- ->setDescriptionHTML($tc->descriptionHTML);
-
- $vCalendar->addComponent($vEvent);
-
- $tc = $tc->next();
- }
-
- header('Content-Type: text/calendar; charset=utf-8');
-
- if ( '0' != $_REQUEST['download'] ) {
- header('Content-Disposition: attachment; filename="zeitumstellung.ics"');
- }
-
- echo $vCalendar->render();
-}