Hello baxter,

Thank you for your reponse, so I've changed my header like this :

$header = array();
$header[] = "Content-length: ".strlen($_entry);  //Header order has changed
$header[] = "Host: localhost";
$header[] = "MIME-Version: 1.0";
$header[] = "Accept: text/xml;";
$header[] = "Authorization: GoogleLogin auth=".$hasil[1];
$header[] = "Content-type: application/atom+xml";
$header[] = "Cache-Control: no-cache";
$header[] = "Connection: close \r\n";
$header[] = $_entry;

but an other error appears:
Method Not Allowed*The request method POST is inappropriate for the URL
/calendar/feeds/default/private/full*

This is the rest of the code

$ch = curl_init();

curl_setopt($ch,CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_URL,"
http://www.google.com/calendar/feeds/default/private/full";);
curl_setopt($ch,CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch,CURLOPT_REFERER, "http://google.com";);
curl_setopt($ch,CURLOPT_VERBOSE, true);
curl_setopt($ch,CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch,CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($ch,CURLOPT_HEADER, true);
curl_setopt($ch,CURLOPT_NOBODY, false);
curl_setopt($ch,CURLOPT_COOKIEJAR, $fCookieFile);
curl_setopt($ch,CURLOPT_COOKIEFILE, $fCookieFile);
curl_setopt($ch,CURLOPT_POST, 1);
curl_setopt($ch,CURLOPT_POSTFIELDS, $post_data);
curl_setopt($ch,CURLOPT_CUSTOMREQUEST,'POST');
curl_setopt($ch,CURLOPT_HTTPHEADER, $header);

I haven't found solution.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Calendar Data API" group.
To post to this group, send email to 
[email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/google-calendar-help-dataapi?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to