获取用户创建的事件
我正在尝试使用 FQL 来检索用户从 Facebook 组织的所有事件。
我首先使用 Facebook 开发者页面上的 FQL 示例。一切顺利。
虽然知道创建者不可索引,但我真的想知道如何检索数据。
我尝试的是:
$fbuser = [facebook_user_id]
$fql = 'SELECT name, venue, location, start_time FROM event WHERE creator='.$fbuser.' AND eid=*';
$ret_obj = $connection->api(array( 'method' => 'fql.query', 'query' => $fql, ));
echo '<pre>'.print_r($ret_obj).'</pre>';
如何避免此错误“”,同时仅获取用户创建的事件?
Im trying to use FQL, to retrieve all of the events the user is organising from Facebook.
I started off with using the example of FQL on Facebook Developer page. All worked well.
While aknowledging that the creator is not indexible, I really want to know how to retrieve the data.
what I tried is:
$fbuser = [facebook_user_id]
$fql = 'SELECT name, venue, location, start_time FROM event WHERE creator='.$fbuser.' AND eid=*';
$ret_obj = $connection->api(array( 'method' => 'fql.query', 'query' => $fql, ));
echo '<pre>'.print_r($ret_obj).'</pre>';
How can I avoid this error "", while getting only the events, the user has created?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
请参阅:http://developers.facebook.com/docs/reference/fql/event_member/
fql?q=SELECT 名称、地点、地点、start_time FROM event WHERE Creator=me() AND eid IN (SELECT eid FROM event_member WHERE uid=me())
唯一需要注意的是您也需要参加该活动。
See: http://developers.facebook.com/docs/reference/fql/event_member/
fql?q=SELECT name, venue, location, start_time FROM event WHERE creator=me() AND eid IN (SELECT eid FROM event_member WHERE uid=me())
The only caveat to this is you need to be participating in the event too.