-2

我有以下从 facebook 获取事件的查询:

$fb_events = $this->facebook->api('/me/events?fields=name,start_time,timezone,location,id,description,cover,picture,venue&limit=1');

但我想从我试过的事件ID中获取:

$fb_events = $this->facebook->api('/$event_id/?fields=name,start_time,timezone,location,id,description,cover,picture,venue&limit=1');

但它不工作

4

1 回答 1

0

尝试这个:

$fb_events = $this->facebook->api('/' . $event_id . '/?fields=name,start_time,timezone,location,id,description,cover,picture,venue');

当然,如果您想获取非公开事件的详细信息,您需要授权被邀请的用户。以下是使用 PHP SDK 执行此操作的方法:https ://developers.facebook.com/docs/php/gettingstarted/4.0.0

于 2014-10-15T17:17:51.530 回答