<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://lug.mtu.edu/w/index.php?action=history&amp;feed=atom&amp;title=PHP_iCalendar</id>
	<title>PHP iCalendar - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://lug.mtu.edu/w/index.php?action=history&amp;feed=atom&amp;title=PHP_iCalendar"/>
	<link rel="alternate" type="text/html" href="https://lug.mtu.edu/w/index.php?title=PHP_iCalendar&amp;action=history"/>
	<updated>2026-04-29T17:47:35Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.17</generator>
	<entry>
		<id>https://lug.mtu.edu/w/index.php?title=PHP_iCalendar&amp;diff=4245&amp;oldid=prev</id>
		<title>Aragirn at 21:36, 14 May 2005</title>
		<link rel="alternate" type="text/html" href="https://lug.mtu.edu/w/index.php?title=PHP_iCalendar&amp;diff=4245&amp;oldid=prev"/>
		<updated>2005-05-14T21:36:42Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;PHP iCalendar is a [http://sourceforge.net SourceForge] project that can be found here: http://sourceforge.net/projects/phpicalendar/. It is a collection of php pages that uses .ics (RFC 2445) files (like those from iCalendar on OS X) to generate a web page containing your schedule on the fly.  Since it&amp;#039;s PHP, it is platform independent, I&amp;#039;m only going to cover OS X though, since that&amp;#039;s what I initially set it up on.&lt;br /&gt;
&amp;lt;p&amp;gt;An example of this is my [http://aragirn.resnet.mtu.edu/cal schedule]. There are a number of ways to give the php pages access to the calendar files. I&amp;#039;ll only cover one method here, and that is setting up a cron script to copy the files to the proper directory. This method assumes that you have not edited any of your system files, if you have, be on the lookout with the changes you have made fresh in your mind.&amp;lt;/p&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Download and install ==&lt;br /&gt;
The first thing that needs to be done though, is to download and untar the project into your Sites folder. After this, you need to enable Personal Web Sharing under the Sharing section of System Preferences. &lt;br /&gt;
&lt;br /&gt;
== Apache ==&lt;br /&gt;
Then, edit /etc/httpd/httpd.conf and make the following changes:&lt;br /&gt;
&lt;br /&gt;
Uncomment the following lines:&lt;br /&gt;
 LoadModule php4_module&lt;br /&gt;
 libexec/httpd/libphp4.so&lt;br /&gt;
 AddModule mod_php4.c&lt;br /&gt;
&lt;br /&gt;
After the line that says: AddType application/xtar .tgz add the following lines&lt;br /&gt;
 AddType application/x-httpd-php .php&lt;br /&gt;
 AddType application/x-httpd-php-source .phps&lt;br /&gt;
&lt;br /&gt;
Find and replace:&lt;br /&gt;
 &amp;lt;IfModule mod_dir.c&amp;gt;&lt;br /&gt;
 DirectoryIndex index.html&lt;br /&gt;
 &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
with:&lt;br /&gt;
 &amp;lt;IfModule mod_dir.c&amp;gt;&lt;br /&gt;
 DirectoryIndex index.html index.php&lt;br /&gt;
 &amp;lt;/IfModule&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then, ina  terminal type:&lt;br /&gt;
 sudo apachectl graceful &lt;br /&gt;
to restart the webserver and allow the changes that were made to take effect.&lt;br /&gt;
&lt;br /&gt;
== Configuring ==&lt;br /&gt;
Next, PHP iCalendar needs to be configured. If you don&amp;#039;t want to change anything, then don&amp;#039;t. If you do, the file is config.inc.php in your phpicalendar folder. It is pretty well documented and things are easy to figure out.&lt;br /&gt;
&lt;br /&gt;
== Updating the calendars used ==&lt;br /&gt;
Now comes the important part: getting your ical files into the directory for PHP iCalendar to use them. To do this, a crontab is going to be added that will copy over the files every five minutes. While not as nice as the instantaneous method WebDAV allows, changes are available reasonably quickly. You will need to edit /etc/crontab to set up the automation of thet script that will be written. The following will set up the calendar copying.&lt;br /&gt;
&lt;br /&gt;
 sudo vim /etc/crontab&lt;br /&gt;
&lt;br /&gt;
Add the following line into the section topped by minute, hour, mday, etc. where each thing goes into a seperate column. Replace kyle with your username.&lt;br /&gt;
 */5    *     *    *    *     kyle     calendar_copy&lt;br /&gt;
&lt;br /&gt;
2) Save and close the file.&lt;br /&gt;
&lt;br /&gt;
3) Create a new file called calendar_copy&lt;br /&gt;
 sudo vim /usr/sbin/calendar_copy&lt;br /&gt;
add the following text to it, while replacing &amp;#039;&amp;#039;&amp;#039;kyle&amp;#039;&amp;#039;&amp;#039; with your username. &lt;br /&gt;
 cp /Users/&amp;#039;&amp;#039;&amp;#039;kyle&amp;#039;&amp;#039;&amp;#039;/Library/Calendars/* /Users/&amp;#039;&amp;#039;&amp;#039;kyle&amp;#039;&amp;#039;&amp;#039;/Sites/phpicalendar/calendars/.&lt;br /&gt;
&lt;br /&gt;
4) Change the permissions on the file to be executable:&lt;br /&gt;
 sudo chmod 755 /usr/sbin/calendar_copy&lt;br /&gt;
&lt;br /&gt;
== Wrap-up ==&lt;br /&gt;
That&amp;#039;s all there is to it. Your site will be available at: http://your-host-name/~your-user-name/phpicalendar/ &lt;br /&gt;
&lt;br /&gt;
Other methods of setting this up include: Using a webdav server or publishing to the php script included in the project, if you wish to do those, check [http://google.com google.]&lt;/div&gt;</summary>
		<author><name>Aragirn</name></author>
	</entry>
</feed>