【问题标题】:What is the correct way, FB Apps "permissions request" page什么是正确的方法,FB Apps“权限请求”页面
【发布时间】:2012-11-08 14:19:34
【问题描述】:

我在“权限请求”页面中测试了我们的 Facebook 应用程序。

根据本站的描述, http://developers.facebook.com/docs/howtos/login/server-side-login/#step5

(A) 正确 如果用户决定在登录对话框中拒绝授权您的应用,他们将被重定向到:


YOUR_REDIRECT_URI?
 &error_reason=user_denied
 &error=access_denied
 &error_description=The+user+denied+your+request.
 &state=YOUR_STATE_VALUE
 ~~~~~~

(B) 但是,我们的测试结果(17/Oct/2012)


 &error_reason=user_denied
 &error=access_denied
 &error_description=The+user+denied+your+request.
 &0=13504605426376027014824690496996#_=_
 ~~

(A)和(B)之间存在差异。 有什么建议吗?

【问题讨论】:

    标签: facebook permissions


    【解决方案1】:

    试试这个

    if($user) {
    
        $me = $fb->api('/me'); 
        } else {
    $url =   "https://graph.facebook.com/oauth/authorize?"
                    ."client_id=app_idxxxxxxxxx&"
                    ."redirect_uri=http://apps.facebook.com/app_idxxxxxxxxx/&"
                    ."scope=user_photos,publish_stream";
        echo "<script language=javascript>window.open('$url', '_parent', '')</script>";
    
            exit();
    }
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2010-10-10
      • 2017-09-09
      • 1970-01-01
      • 2014-09-23
      • 1970-01-01
      • 2011-11-19
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多