简体   繁体   English

我如何阅读Facebook活动的墙?

[英]How do I read the wall of a facebook event?

I have a successfully authenticated user logged into my app through facebook, I want to read the wall / information of an event the user created. 我有一个成功通过身份验证的用户通过Facebook登录到我的应用程序,我想读取该用户创建的活动的背景墙/信息。 My code is returning an empty array with just [data] => (). 我的代码返回的只是[data] =>()的空数组。 The event id is valid taken from the URL of the event. 事件ID有效地取自事件的URL。 Any links as to where to find relevant documentation on this is greatly appreciated. 非常感谢有关在哪里可以找到相关文档的任何链接。 Do I need to request any extra permissions from the user when logging in? 登录时是否需要向用户请求任何其他权限?

    <?php
    require 'facebook.php';

    $facebook = new Facebook(array(
      'appId'  => 'XXXXXXXX',
      'secret' => 'XXXXXXXX',
      'cookie' => true
    ));

    $user = $facebook->getUser();

    $page_id = 'XXXXXXXX';
    $pageFeed = $facebook->api('/'.$page_id.'/feed');

    print_r($pageFeed);

    ?>

检查您是否具有user_events 权限 -访问用户事件和/或这些事件的提要需要此权限

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM