dongling5411 2018-03-27 14:37
浏览 184
已采纳

此网址的域名未包含在应用的域中。 (子域!)

my question is the same as this:

Facebook App - The domain of this URL isn't included in the app's domains. Why?

except that my url is: http://ccc.nnn.hhh.hu

The settins on fb, "facebook login":

Client OAuth Login: ON

Web OAuth Login: ON

Valid OAuth Redirect URIs: http://ccc.nnn.hhh.hu/my.php

strict mode is ON (cannot be disabled)

At basic:

App Domains: http://ccc.nnn.hhh.hu

so, when trying to login, the facebook dialogs asks for the username and password, so far so good. And then I get an exception for this:

$fb = new Facebook\Facebook([
    'app_id' => aeaeae,
    'app_secret' => rrrrr,
    'default_graph_version' => 'v2.5'
]);

$helper = $fb->getRedirectLoginHelper();
$accessToken = $helper->getAccessToken();

and I wont get the $accessToken but the execption:

The domain of this URL isn't included in the app's domains.

  • 写回答

2条回答 默认 最新

  • douqi3913 2018-04-24 12:53
    关注

    Right, you have to upgrade the sdk to "5.6.2" to support strict mode.

    Facebook is forcing strict mode by default now, and that implies that we should use a standard redirect URL, or declare our old custom URI in the Valid Oauth redirect URIs list. See:

    https://developers.facebook.com/blog/post/2017/12/18/strict-uri-matching/

    So, apart from upgrading the sdk, you guys want to add your custom URI in the list to support legacy app flows.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 Vue3 大型图片数据拖动排序
  • ¥15 划分vlan后不通了
  • ¥15 GDI处理通道视频时总是带有白色锯齿
  • ¥20 用雷电模拟器安装百达屋apk一直闪退
  • ¥15 算能科技20240506咨询(拒绝大模型回答)
  • ¥15 自适应 AR 模型 参数估计Matlab程序
  • ¥100 角动量包络面如何用MATLAB绘制
  • ¥15 merge函数占用内存过大
  • ¥15 使用EMD去噪处理RML2016数据集时候的原理
  • ¥15 神经网络预测均方误差很小 但是图像上看着差别太大