Ben denemek ve benim olay için insanları davet ederken bu hatayı alıyorum: 114 geçerli bir kimlik dizesi (örneğin, "123") yöntemi events.invite olmalı ...
İşte benim php5 kodu:
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://www.facebook.com/home.php");
curl_setopt($ch, CURLOPT_USERAGENT, "Firefox/3.5");
curl_setopt($ch, CURLOPT_COOKIEJAR, __DIR__ . "/cookie-jar/cookie.txt");
curl_setopt($ch, CURLOPT_COOKIEFILE, __DIR__ . "/cookie-jar/cookie.txt");
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 0);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);
curl_exec($ch);
$info = curl_getinfo($ch);
curl_setopt($ch, CURLOPT_URL, "https://login.facebook.com/login.php");
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, "email=".urlencode($this->USERNAME)."&pass=".urlencode($this->PASSWORD));
curl_exec($ch);
sleep(10);
curl_setopt($ch, CURLOPT_POST, 1);
$URL = "https://api.facebook.com/method/events.invite";
curl_setopt($ch, CURLOPT_URL, $URL);
$POST_FIELDS = "eid=$EID&uids=$UIDS&access_token={$this->TOKEN}";
curl_setopt($ch, CURLOPT_POSTFIELDS, $POST_FIELDS);
$events = curl_exec($ch);
print_r($events);
Herhangi bir fikir?