Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
33 lines (24 sloc) 1.17 KB

cl-calendarimport

NOT COMPATIBLE WITH OWNCLOUD 9 - WON'T FIX

PHP command line script for importing calendar files into your ownCloud calendar

License

This project is licensed under the terms of the MIT License.

How to setup:

  • set the correct path for OCROOT on line 25

Attention

  • all existing events in the calendar will be deleted before importing the file

Parameters

  • user of webserver - checkout your distros doc
  • name of this script - should be automatedimport.php if you didn't rename it
  • userid of calendar owner - userid of the calendars owner, probably your userid
  • id of calendar - to get this id, take a look at the table %prefix%calendar_calendars in your database
  • valid PHP timezone - checkout http://www.php.net/manual/en/timezones.php

How to run this script from command line:

$ sudo -u <user of webserver> php <name of this script> <absolute path to calendar file> <userid of calendar owner> <id of calendar> <valid PHP timezone>

Example on debian:

$ sudo -u www-data php automatedimport.php /home/georg/somerandomicsfile.ics georg 7 Europe/Berlin
You can’t perform that action at this time.