I'm trying to get list of Yahoo calendars using the next code.
$url = "https://calendar.yahoo.com/";
$user = "****@yahoo.com";
$pwd = "*****";
$body = "<A:propfind xmlns:A='DAV:'>
<A:prop>
<A:displayname/>
</A:prop>
</A:propfind>";
$c=curl_init($url);
curl_setopt($c, CURLOPT_HTTPHEADER, array("Depth: 1", "Content-Type: text/xml; charset='UTF-8'", "User-Agent: DAVKit/4.0.1 (730); CalendarStore/4.0.1 (973); iCal/4.0.1 (1374); Mac OS X/10.6.2 (10C540)"));
curl_setopt($c, CURLOPT_HEADER, 0);
curl_setopt($c, CURLOPT_SSL_VERIFYHOST, 0);
curl_setopt($c, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($c, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);
curl_setopt($c, CURLOPT_USERPWD, $user.":".$pwd);
curl_setopt($c, CURLOPT_CUSTOMREQUEST, "PROPFIND");
curl_setopt($c, CURLOPT_POSTFIELDS, $body);
curl_setopt($c, CURLOPT_RETURNTRANSFER, 1);
$data=curl_exec($c);
curl_close($c);
But in response i've got 500 Error. Any idea?
Also I'm trying use this link https://caldav.calendar.yahoo.com, but it's too 500 Error