Other users cant login using facebook's api on localhost

*爱你&永不变心* 提交于 2019-12-12 02:54:10

问题


I'm working with the PHP SDK on localhost. I've looked at other questions posted on here like this: Can't login to website using facebook's api's

Domains, urls, login urls all match. The app secret and id match, sandbox was never turned on (double checked to make sure). I had trouble moving it to a new laptop, cuz the folder i put it in was called something else. After i changed that it worked fine.

The problem I'm having is, I as the owner of the app can log in and it does what i want it to do, but if i have a friend, or another user try to log in, it asks for permissions, then shows the "An error has occured, Please try later" facebook error page. Not entirely sure why its doing this, because i havn't hardcoded my info into it at all.

I've used different browsers, cleared cookies, nothing seems to work. Any ideas would be helpful.

EDIT: i've also tried destroying the session before login, didn't help.

Thank you.


回答1:


Other people cannot access your app 'on localhost' if they are not using your computer, which is the local host.

If you want other people to be able to use your app, they'll need a copy of your code, running on their local machine, or you'll need to make it available via a publicly accessible IP and/or domain name.



来源:https://stackoverflow.com/questions/14760994/other-users-cant-login-using-facebooks-api-on-localhost

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!