[英]why $facebook->getUser() return 0?
My code is 我的代码是
include_once "fbaccess.php";
$user_id = $facebook->getUser();
var_dump($user_id);
var_dump($facebook);
Result:- 结果:-
int(0) // Why $user_id return zero
object(Facebook)#1 (7) {
["appId":protected]=> string(15) "4545454"
["appSecret":protected]=> string(32) "323232"
["user":protected]=> int(0)
["signedRequest":protected]=> NULL
["state":protected]=> string(32) "c8d6e657da34596785b06e7511921529"
["accessToken":protected]=> string(48) "{APP_SECRET}"
["fileUploadSupport":protected]=> bool(false) }
Please help me. 请帮我。 Which thing i have missed???? 我错过了哪件事????
Have a look at https://developers.facebook.com/docs/php/gettingstarted and stick to the given example. 看看https://developers.facebook.com/docs/php/gettingstarted并坚持给定的示例。 The code you posted is incomplete and will not work like this. 您发布的代码不完整,因此无法正常工作。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.