drpkcwwav20524605 2014-02-05 16:48
浏览 97
已采纳

不允许使用Facebook PHP SDK URL

I'm trying to login with my FB-account on my website http://www.example.com/index.php. I have replaced the AppId && Secret. I have also added a website-platform in the settings where I've set the "Site URL" to http://www.example.com/

But when I do $facebook->getUser() it always returns 0. And when I insert the login-link with $facebook->getLoginUrl() and I click on the link it redirects me to

https://www.facebook.com/dialog/oauth?client_id=AppId...

On this page facebook tells me that my App-Settings don't allow the URL

  • 写回答

1条回答 默认 最新

  • dsfdsf8888 2014-02-05 17:24
    关注

    You have to configure this in your Developer Console on facebook.

    It's under Settings> App Domains

    note that if you just do "www.example.com" - then you will need to make sure that the API request is coming from "www.example.com" - and not "example.com"

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥20 有关区间dp的问题求解
  • ¥15 多电路系统共用电源的串扰问题
  • ¥15 slam rangenet++配置
  • ¥15 有没有研究水声通信方面的帮我改俩matlab代码
  • ¥15 对于相关问题的求解与代码
  • ¥15 ubuntu子系统密码忘记
  • ¥15 信号傅里叶变换在matlab上遇到的小问题请求帮助
  • ¥15 保护模式-系统加载-段寄存器
  • ¥15 电脑桌面设定一个区域禁止鼠标操作
  • ¥15 求NPF226060磁芯的详细资料