0

I am trying to add event to user calendar through Davical Client Library caldav-client.php.

Hence, I used DoPUTRequest() function. Server Responds with OK. But unable to see event in Calendar Client (CalDavZap).

Please find the bellow scenario:

The Event need to added in user webcalu1

I created object as:

$cal = new CalDAVClient("http://myserver/davical/caldav.php/webcalu1/calendar/", "webcalu1", "password", "calendar");

And Formed iCalendar string and relative URL as

$icalendar = <<<EOD
  BEGIN:VCALENDAR
                  BEGIN:VEVENT
                  UID:test123
                  SUMMARY:Test Event
                  DTSTART=20150820T080000
                  DTEND=20150821    T170000
                  END:VEVENT
                  END:VCALENDAR

EOD;

$relative_url = '/tselvan/calendar/';

And Called the function

$response = $cal->DoPUTRequest($relative_url, $icalendar, '*');
echo $response;

The Response From Server is:

HTTP/1.1 200 OK Date: Fri, 14 Aug 2015 08:09:29 GMT
Server: Apache/2.4.7 (Ubuntu)
Access-Control-Allow-Origin: *
Access-Control-Allow-Methods: GET,POST,OPTIONS,PROPFIND,PROPPATCH,REPORT,PUT,MOVE,DELETE,LOCK,UNLOCK
Access-Control-Allow-Headers: User-Agent,Authorization,Content-type,Depth,If-match,If-None-Match,Lock-Token,Timeout,Destination,Overwrite,X-client,X-Requested-With Access-Control-Allow-Credentials: false
Access-Control-Expose-Headers: Etag
X-Powered-By: PHP/5.5.9-1ubuntu4.11
DAV: 1, 2, 3, access-control, calendar-access, calendar-schedule
DAV: extended-mkcol, bind, addressbook, calendar-auto-schedule, calendar-proxy
X-DAViCal-Version: DAViCal/1.1.1; DB/1.2.11
Content-Length: 0
Connection: close
Content-Type: text/plain; charset="utf-8" 

Could you please anyone help me "Where am doing wrong? otherwise "How should I proceed?".

Thanks

trogper
  • 1,516
  • 1
  • 12
  • 14
JsLearner
  • 446
  • 2
  • 7
  • 17
  • iCalendar String As : $icalendar = << – JsLearner Aug 14 '15 at 08:25
  • 1
    A lot of software doesn't display floating events with time properly. Try adding a timezone or a Z (UTC) to the value as a starter. ps: you might want to edit the question to include all this data. – hnh Aug 14 '15 at 22:42

0 Answers0