突然,getUser成为返回0.(PHP 3.1.1 SDK) [英] suddenly, getUser became to return 0.(PHP 3.1.1 SDK)
问题描述
只有10小时前,如果我打电话给$ $ $ $ $ $ $ $ $ $ $ $ $ $ $ $ code code code code>,但现在,它总是返回0.在cource中,我没有改变我的代码。
Only 10 hours ago, if I call $facebook->getUser()
, I can get the correct user_id
, but now, it always returns 0. Of cource, I have not changed my code.
还有一个奇怪的点。
redirect_url
包含:
?sate = 9b1772342342。 ..& code = 9b177asd2l ..& base_domain = 9b1772.3423# =
我可以不要发布网站..请帮助!
I can't release the site.. Please help!
推荐答案
我认为这是一个Facebook错误,我刚刚完成了自己的想法。您需要更改Base_Facebook类,并添加一个新的查询参数以将其删除。 base_domain参数被意外地添加到重定向网址,希望很快就会出现修复。
I think this is a Facebook bug, I just finished figuring it out myself. You need to alter the Base_Facebook class, and add in a new query param to strip out. The base_domain param is being accidentally appended to the redirect url, hopefully a fix will be rolled out soon.
/**
* List of query parameters that get automatically dropped when rebuilding
* the current URL.
*/
protected static $DROP_QUERY_PARAMS = array(
'code',
'state',
'signed_request',
'base_domain', // this is the one you need to add
);
这篇关于突然,getUser成为返回0.(PHP 3.1.1 SDK)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!