WP-iCal: WordPress iCal Event Plugin

The WP-iCal plugin turns WordPress into a multi-author, online calendar. The plugin takes any posts in a ‘Calendar’ category and writes them to an .ics file ready for subscription into Apple’s iCal, Mozilla Calendar or other vCal-friendly app.

If you’d like to see it wp-ical in action, check out MNterative.com. If you’re running WP-iCal on your site, let me know and I’ll add you to this list.

WP-iCal 2008-11-12.166 – updated by Andrew Koransky – is the latest version, Download WP-iCal 2008-11-12.166

Download WP-iCal v0.9.7.1

Download WP-iCal BETA 2006-10-12

Like the WP-iCal? Say thanks and support its continued development via paypal

How To Use WP-iCal 0.9.x

  1. Upload an empty file to the root of your WordPress directory with the file name: “calendar.ics” and make it writable
  2. Change the $calpath variable in wp-ical.php (line 29) to the server path (often starts with /usr/home/). If you’re running v 0.9.5 or earlier, please download the latest version.
  3. Install the wp-ical.php file in your WordPress Plugins directory and activate.
  4. Create a ‘Calendar’ category in your WordPress installation. WP-iCal will look in this category to populate the calendar.ics file
  5. You will now see a ‘Calendar Event Details’ form when you create or edit a post in WordPress.
  6. Entering location information to a post will add it to the calendar.ics file.

How To Use WP-iCal 2006-04-11 and later

  1. Upload the wp-ical.php file in your WordPress root directory
  2. Upload the wp-ical-plugin.php file in your WordPress Plugin directory and activate
  3. Point your browser to the wp-ical.php file.

WP-iCal is released under the GNU General Public License.

Things to do before v1.0
Create iCal file and set permissions programmatically
Add list of Timezones
Support multiple calendars
– Write reference and read me info
– Connect to other calendar systems; i.e. Upcoming.org
– Maybe some Google Maps?

Version History
2006-10-12
– Fixed bug where single-digit hours were throwing off the minutes.

2006-09-01
– Fixed bug where all-day even flag wasn’t being set correctly.

1.0b (Released 14 Dec 2005)
– Can now create all day and multi-day events

0.9.7.1 (Released 11 Jul 2005)
– Resolved issues where calendar data didn’t acutally save

0.9.7 (Released 10 Jul 2005)
– Compatible with WordPress 1.5 “Strayhorn”

0.9.6 (Released 10 Apr 2005)
– Plugin now looks for ‘calendar.ics’
– Added the ‘How to Use’ instructions above

0.9.5 (Released 07 Mar 2005)
– Calendar is neow created when posts are saved and edited
– Stripping out funny characters so event location and post description are correctly loaded in the calendar
– Fixed bug with changes to event’s location, start time, and end time not updating correctly
– Known Issues: there’s a couple of stray slashes here and there, if you see something odd, add it to the comments.

0.9 (Released 05 Mar 2005)
– Using wp-postmeta tables to store event location, start time, and end time
– Events in iCal now use wp-postmeta information for location, start time, and end time
– Known Issues: Updates to location, start time, and end time don’t function correctly from Calendar Event Detail fields – use WordPress’s built-in meta fields for now.

0.8 (Released 15 Feb 2005)
– Using post’s publish date as event start time.

59 comments for “WP-iCal: WordPress iCal Event Plugin

  1. February 15, 2005 at 9:07 pm

    Are these published once or are changes to the post reflected in the calendar again?

    this sounds like a very neat idea, and i’m excited to see how you approach the setting of the time and the duration of the event.

  2. February 16, 2005 at 10:47 pm

    Right now, the event’s date/time is the same as the post’s publish date/time. For this version, the event’s duration is hard-coded at 1hr. Hoping to find a better solution to both of these before a v1.0 release.

  3. February 22, 2005 at 9:01 am

    Great idea ! Is there a demo site where I can see it in action before trying it ? Tx.

  4. February 22, 2005 at 9:26 am

    Fabian, yes, it’s running at MNteractive.com.

  5. Van Garrick
    February 23, 2005 at 7:14 pm

    Just looking for my name, found yours.

  6. February 27, 2005 at 3:50 pm

    I downloaded the plugin but I can’t seem to find out how it’s supposed to work. I don’t see anything new in the admin’s Write post page and there are no ics files generated anywhere when I post a new (future) event.

    I’ve also fixed a small bug (time zone hardcoded eventhough there’s a variable for it).

    Please contact me by email for the updated file. It’s also not clear what licence you distributed this under. I’d suggest GPL.

  7. April 6, 2005 at 10:04 pm

    I’m trying out wordpress for our notes on properties and discovered your calendar plugin. I installed the pluginn alright, however I do not see where the .ics file is created? Where should the .ics file appear?

  8. April 7, 2005 at 7:41 am

    Jonas,

    You’ll need to create the .ics file manually and set the permissions so it’s writable.

    Programmatically, I’m not able to set the permissions of the file so WordPress can to write to it.

  9. April 9, 2005 at 2:20 pm

    Hi, sorry, I have also a problems. no .ics file, nothing is written on the server-path…. I created the file and did the permission to chmod 666… nothing happens

  10. April 9, 2005 at 2:53 pm

    Martin, a couple things to check:

    1. If are there spaces in your .ics file name? If there are, change them to either %20 or an underscore and update the wp-ical file appropriately.

    2. The path to the .ics file should be the absolute path, often starting with ‘/usr/…’

    3. Jonas had more luck adding ‘location’ and ‘start time/end time’ info to new posts and getting them to show up in the .ics file rather appending that info to old ones.

    Does this help?

  11. April 18, 2005 at 12:00 pm

    Hi, this is a very cool idea.
    I have it working and am integrating it with
    phpicalendar. Together they make a nice solution.

    The one issue I’m having is that I would like for the multi-day events to show up in ical/phpicalendar as multi-day events.
    Right now if I have an event that goes from April 21 – April 26th, it just posts it to April 21st.
    Any ideas for me, or is this related to the time duration (set at 1 hr)? Even if it was set at 1 hour, it seems like it should still display across all days.

    At any rate, thanks for your work. This is cool.
    b

  12. April 18, 2005 at 12:07 pm

    Ben,

    First, make sure you have the wp-ical 0.9.6, you should be able to set the events for longer than an hour. Also, I’ve found multiple day events to be a little tricky – and I’m investigating exactly what the issue is. That being said, I was able to get one to work in the mnteractive.ics:
    24 Hr Comic Challenge on April 23-24th.

  13. Pingback: CentronX.net
  14. May 24, 2005 at 4:10 pm

    Hi, I’ve just coded up something very similar to this. However I think I’ve taken a slightly different approach from you. My solution is a .php file that generates the vCalendar data on the fly, each time it is asked for.

    The author may set the ‘duration’ custom field to change the event’s duration.

    Details here: http://blog.firetree.net/2005/05/24/eventcalendar2/

  15. Kirk Spencer
    May 28, 2005 at 4:37 pm

    OK, I have to be misunderstanding something.

    I’ve got calendar.ical (chmod 666) in
    /var/www/localhost/htdocs/wordpress/

    I changed line 29 to read exactly that.

    I put wp-ical.php in the above’s plugins directory.

    I can see the plugin in the manager. But when it’s applied, I can’t see a calendar edit element when writing.

    Got an idea?

  16. May 28, 2005 at 4:49 pm

    Kirk,

    Verify the wp-iCal plugin is active, and then drop me an email if you still don’t see the ‘Calendar Event Details’ section in the ‘Write Post’ screen.

    Thanks.

  17. tim
    June 10, 2005 at 3:14 am

    Garrick,

    do you know how to generate the UID for the ical File with php? Think that’s the biggest problem for creating the .ical File with php.

    Regards tim

  18. June 10, 2005 at 7:42 am

    Great question Tim. In my experience, iCal generates the UID automatically when it parses the wp-ical data.

  19. June 12, 2005 at 12:36 am

    Great, everything works.
    Except when you delete a post, it stays in the .ics file. It doesn’t happen much I guess, but if you deleted an event, you’d probably want it removed from the calendar file.

  20. tim
    June 14, 2005 at 3:07 pm

    garrick, could you please show me the light.

    My problem is I can’t find the format describtion for theese UID (example below). Is there a kind of generation function in php available.

    the next lines are from a ical file created by mozilla’s calendar

    BEGIN:VCALENDAR
    VERSION
    :2.0
    PRODID
    :-//Mozilla.org/NONSGML Mozilla Calendar V1.0//EN
    BEGIN:VEVENT
    UID
    :9c997280-d91c-11d9-8c79-e1caa475472b
    SUMMARY
    more details and events start here

    regards tim

  21. June 17, 2005 at 7:34 am

    tim,

    Is the .ics file you’re creating being successfully read by iCal or Mozilla without the UID?

  22. tim
    June 21, 2005 at 1:29 am

    hi garrick,

    i found a really useful php class for creating ical files on
    sourceforge

    now i’m able to export my sportleagues to ical-files. The sportleagues based on a php application called Liga Manager Online

    Regards tim

  23. June 22, 2005 at 4:08 am

    Hi,
    I’m using Thunderbird with a company’s ical… how about the functionality that I can enter a new event or duty locally and upload it to WPcalendar? Or is that already possible?
    regards,

    Grendel

  24. June 30, 2005 at 9:50 am

    Garrick…I’m a bit dense right now (vacation’s next week!). And I can NOT gather from your example what WP-iCal does, and of course, because the synapses aren’t firing right now and I’m swamped, I’m not just “demoing” it to kick the tires…wanna SEE it first.

    Here’s my situation: my wife and I need a way to CO-EDIT a calendar and schedule appointments for a project. iCal’s not cutting it since we’re BOTH adding dates. Of course, she could email or iChat me the date and I could put it on, but that is just a workaround. And we BOTH use WP for our respective blogs. Could your plugin be the answer?

    Thanks!

  25. June 30, 2005 at 9:58 am

    That’s exactly why I created the wp-ical. Originally created for MNteractive.com, a multi-author wordpress blog, the idea was to have that’s able to post be able to add items to the ics file. So, yes, wp-ical could be the answer.

    MNteractive is going through a redesign right now and I believe the ics file is unavailable at this moment.

  26. ooga
    August 8, 2005 at 4:36 pm

    i have no clue how this plugin works, are we suppose to put a link manually where people can subscribe to the ical ?

  27. ooga
    August 9, 2005 at 11:34 am

    this plugin is complicated to figure out

  28. John Davis
    August 11, 2005 at 6:17 am

    I just set this up for a band website, and integrated it with PHP iCalendar. The two together are incredibly elegant.

    One question: is it possible to set up recurring events? If not, may I suggest that as a feature for 1.0?

    Thanks for the great plugin.

    – John

  29. August 11, 2005 at 1:39 pm

    Garrick,

    I am going to be creating my calendar for a church of several hundred people. In Sunbird, there is an option to save changes back to the server. Will parishioners be able to make changes to the calendar or is that only if they have the login credentials for the server? I have a test cal working on my site, but I can’t let it go live for my church until I have a response to this.

    Regards,
    Jamie

  30. August 11, 2005 at 1:45 pm

    Oh, and I forgot to ask whether there is a way to support untimed events such as holidays.

  31. August 14, 2005 at 6:50 am

    Multiday (or all day) events don’t seem like they’re too big of a deal. I’ve hand-edited the .ics file iCal Event makes to get it to work.

    You simply drop the times completely from the event start and stop dates and add one day to the stop date.

    Once change I’d like to suggest is that it only tries to write or update the .ics file if the post is in the Calendar category. It seems like a waste to fire this function everytime a post is added. I had one post with two long links with lots of funky characters and the system bogged down.

  32. September 5, 2005 at 1:01 pm

    I hate broken plugins. I have uploaded the wp-ical.php into my plugins directory, and created a blank calenar.ics in the root directory of my blog.. i chmod’d the file 777 just in case. I can see the enter location field in my create post forms now, however when I add a post and add an event location.. the post creates under the category “Calendar”, however the calendar.ics remains blank..

    This really sucks, I was looking forward to this.
    Let me know whats going on please.

    mindamp
    mindamp@mindamp.org
    http://www.mindamp.org

  33. October 7, 2005 at 4:34 pm

    This sounds like a grrreat plugin. However, I’m not sure what I’m doing wrong.

    I think I have everything set up as described. The posts appear but the .ics file doesnt’t get changed. It is still empty.

    Do I need _anything_ in that file? Totally blank is correct?

    In the wp-ical.php file there is a link (34) that has a $calfile variable. Bydefault it says $calfile = urlencode(get_settings(‘blogname’)) . “.ics”;

    Should this be change to have the actual blogname? Should it be changed to be the name of the .ics file minus the extension?

    I would love to get this working. Thanks in advance for any help.

    j

  34. November 10, 2005 at 9:05 pm

    The plug-in is definitely also pulling in static pages into the ics file on my site. The plug-in should do an additional check to make sure the post status is not “static”.

    Maybe it’s pulling in the pages because there is only one post category on my site and WordPress sets a 0 for post_category even for static pages?

    http://www.evvyawards.org/25/EVVY25.ics is a sample file showing the static posts being included.

  35. November 10, 2005 at 9:18 pm

    Correction to my last post about static pages being included in the ics file: I didn’t realize that WP stores a post’s category assignment in post2cat table. The problem is that static pages, even though they have no category assignment, are assigned the default category (usually 1). I only have one category for posts (the calendar) on my site, so all of my static pages are appearing as entries on the calendar (because calendar posts are the default category and it is the only category to have ever existed on my site). The plug-in *must* do a check to see if the post’s post_status is publish to avoid this problem.

  36. Drolsum
    December 14, 2005 at 6:06 am

    Hi!

    I am testing your calendar plug-in, and it shure looks exciting. I’ve made a empty file, equal to the Blog’s name. It works, and events is added. But,

    1. I cannot remove events – or events did not go away, when I deleted them from the blog. Any hints on this? Maybe it has something to do with:

    2. The code is wrapped to ten lines, and makes it a bit hard to read.

    3. Is it possible to make «all-day events», events that floats on top of iCal, rather than filling up all space in the program? (Was this understandable?)

    Thank you!

  37. January 18, 2006 at 1:09 am

    I get this error…
    The file /homepages/24/d90228368/htdocs/cal/calendars/ The+Journeyler.ics is not writable

    what am I doing wrong the folders and the files are either chmod 777 or 666
    I have tried labeling the new calendar files as the variable in the sheet example and as “The Journeyler.ics” or as “calendar.ics”
    I am on wordpress 2.0

  38. Jim
    January 29, 2006 at 1:23 pm

    Hi,

    I was wondering if there was any way to post using email and have it be entered into the Calendar. I am new to wordpress and not sure where to look to figure it out. I have a group of friends I want to be able to email a single address that would post instead of our mailing list. Then it could populate the blog, our calendars, and if they want they could subscribe to specific topics.

    It’s a nice plugin and hope this is possible. Thanks.

  39. October 30, 2007 at 3:48 pm

    I am using WP-ical to create a .ics file that is then read by a web program that displays the contents on my website in a calendar. I recently upgraded to the most recent version and now I cannot find where I can change the path to drop the .ics file where I want it. Furthermore, isn’t the new file a vcal file? Is there an option to keep it a .ics file?

  40. October 30, 2007 at 4:18 pm

    in the latest version of wp-ical, there’s a standard path to the file, http://path_to_your_blog/wp-ical.php

    The resulting file is the same as in previous versions.

  41. December 11, 2007 at 10:57 am

    thx for this little but very useful plugin!

  42. daniel
    February 20, 2008 at 11:05 am

    Seems like a very cool plugin. I played around with it this day and it works like a charm. Thank You! By the way are there any known issues with uptodate WP versions like 2.3.3? Is this plugin still under active development?

  43. February 20, 2008 at 11:28 am

    Thanks Daniel. Glad it’s working well for you. It’s still under active development, it just hasn’t needed any attention for a while…it does what it does well.

Leave a Reply

Your email address will not be published. Required fields are marked *

You should get my email