OAuthException : An active access token must be used to query information about the current user

百般思念 提交于 2019-12-01 17:50:02

You must ensure that your access token is active. Or maybe you're in logout condition. Or try to clean the cookies and cache from your browser (ctrl+shift+del)

Mangesh Navale

Please check if you are getting any Facebook exceptions like

An active access token must be used to query information about the current user.

which causes 0 as user id in return from $facebook->getUser().

So please check with getAccessTokenFromCode() from base_facebook.php and verify access_token_response format as it may be in JSON format.

So try to use appropriate decoding method to get $response_params['access_token'] from $access_token_response.

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