Donate Share

PHP iCalendar

Tracker: Bugs

5 Attendee parsed with additional tags - ID: 1190302
Last Update: Comment added ( jimhu )

In and event the ATTENDEE may look like this
ATTENDEE;CN=The
Name;RSVP=FALSE;PARTSTAT=ACCEPTED;ROLE=REQ-PARTICIPANT;X-UID=vcard.ll-196:m
ailto:name@somewhere

currently everything is extracted as name and looks very
scary if the user clicks on the event to see it's details.

I have fixed it like this:
case 'ATTENDEE':
$attendee[] = array ('name' =>
ereg_replace ("ATTENDEE;CN=([^;]*).*", "\\1", $field),
'email' =>
ereg_replace (".*mailto:(.*).*", "\\1", $field),
'RSVP' =>
ereg_replace (".*RSVP=([^;]*).*", "\\1", $field),
'PARSTAT' =>
ereg_replace (".*PARTSTAT=([^;]*).*", "\\1", $field),
'ROLE' =>
ereg_replace (".*ROLE=([^;]*).*", "\\1", $field));
break;

I have added parsing for additional fields which may be
used in the future.


Gerald Weber ( geraldweber ) - 2005-04-26 14:27

5

Closed

Fixed

Jim Hu

Parsing iCals

v2.0

Public


Comments ( 5 )

Date: 2008-12-26 09:11
Sender: jimhuProject Admin

Please test this problem with the latest version of PHP iCalendar in CVS
and let
us know if it fixes your problem.


Date: 2008-12-26 09:11
Sender: jimhuProject Admin

patch applied


Date: 2006-10-11 19:36
Sender: thundercorp

Logged In: YES
user_id=90940

Groupwise also adds these tags. You may need to add ROLE as part of the
ORGANIZER as Groupwise seems to make this display:
Organizer: "Mr Example";ROLE=CHAIR


Date: 2005-05-17 08:06
Sender: geraldweber

Logged In: YES
user_id=219134

Sorry, forgot to mention which program was used. It's korganizer
version 3.3, now part of kontact version 1.0.



Date: 2005-05-16 19:43
Sender: davefd2

Logged In: YES
user_id=1272374

Do you have a sample ics file? What program generates
ATTENDEEs in this format?


Attached Files ( 2 )

Filename Description Download
attendee.php modified part of ical_parser.php Download
sample.ics Sample of VEVENT with ATTENDEE generated by korganizer 3.3 Download

Changes ( 5 )

Field Old Value Date By
status_id Open 2008-12-26 09:11 jimhu
resolution_id None 2008-12-26 09:11 jimhu
close_date - 2008-12-26 09:11 jimhu
File Added 134776: sample.ics 2005-05-17 08:11 geraldweber
File Added 131810: attendee.php 2005-04-26 14:27 geraldweber