PHP iCalendar Authentication Issues

Posted in: Tasks Pro™

I get by far the most support questions about trying to view the tasks iCalendar in the included PHP iCalendar.

I hacked some 401 authentication support into PHP iCalendar, but it doesn’t work for some people. I think it depends on server config and PHP version.

One solution is to go into the PHP iCalendar config file and add the tasks iCalendar with your username/password to the ‘$list_webcals[]’ setting. It should look like this:

$list_webcals[] = ‘http://username:password@www.example.com/tasks/ics.php’;

After you do this, you then need to change line 7 in the calendar.php page to from this:

$URL = $custom->ical_URL."month.php?cal="
.urlencode($custom->tasks_URL.’ics.php’)
.”&getdate=”.date(”Ymd”);

to this:

$URL = $custom->ical_URL."month.php?getdate="
.date(”Ymd”);

The ‘tasks Webcal’ should show up in the drop down of Calendars.

I should make this a setting and add these notes to the poor neglected docs.

Popularity: 3% [?]

Posted November 22nd, 2003 @ 11:04 PM

4 Replies

  1. Gabe adds this Comment:

    Hmmm… as far as catching the 401 error is concerned, I think the most fool proof method may be to search the headers. See http://www.php.net/m[...]ers.http.php for how to do that. Annoyingly it looks like there are two different ways to do it depending on if PHP version < 4.3.0.

    The authentication isn’t working for me, but I think it has to do with the fact that I have tasks installed in a directory that is already controlled via .htaccess.

    March 23rd, 2004 at 9:42 pm

  2. Gabe adds this Comment:

    Ack. < wasn’t encoded and the end of my comment is cut off.

    By the way, I turned off .htaccess auth everything worked great. Note that I was restricting access by IP address which made the login box that popped up a moot point. If the error is 403 then it should return ‘bad configuration’ or some such error.

    March 23rd, 2004 at 9:52 pm

  3. Alex adds this Comment:

    I wish PHP iCalendar would add this feature to their app so I wasn’t trying to hack around it.

    March 23rd, 2004 at 9:56 pm

  4. nick adds this Comment:

    I wish PHP iCalendar would add this feature to their app so I wasn’t trying to hack around it.

    November 15th, 2005 at 3:09 am

Add a Comment

Please note: Use of a non-personal web site or blog in the field below and/or comments that are off-topic, personal attacks, or support requests will likely be removed at my discretion.

Note: This post is over 5 years old. You may want to check later in this blog to see if there is new information relevant to your comment.

Around the web » « Love Actually

About This Site

This is the personal web site of Alex King, a web developer in Denver, Colorado USA. More...


Crowd Favorite

Crowd Favorite is my software and web development business.

We build web applications, design and develop custom WordPress themes and plugins, and build custom sites using WordPress as a CMS.


I also have a tumblog that aggregates my online content from other services (Twitter, Flickr, del.icio.us. etc.).

America

Ads

Get Group Health Insurance
Car Loans available here