Using publish.php

From PHPicalWiki

Jump to: navigation, search

publish.php is a script that allows phpicalendar installations without WebDAV to do WebDAV-style publishing. Once a calendar is published via publish.php, ical or mozilla calendar (whichever published it) should be able to automatically update the calendar on the server.

publish.php replaces two older scripts that were for ical and mozilla. These may still be in your distribution, but they should not be used - they have known security holes.

[edit] Setup

  • Make sure that publish.php is in the directory where you want to upload the calendars. If you are using more than one directory, make copies of publish.php (or symlinks) in each one. Since publishing the calendars involves including publish.php in the upload URL, your calendar program has to be able to find publish.php.
  • Make sure that your webserver can write to the directory. Otherwise publish.php will not be able to copy the calendars to the directory, and it won't be able to write its logfile. Note that it is not a good idea to make the directory writeable by anyone. Hackers can deposit malicious php scripts in such directories if they are not secure, and can do lots of damage if they do.
  • Turn WebDAV-style (as opposed to real WebDAV) publishing on in config.inc.php
$phpicalendar_publishing = '1';

[edit] Security