[英]Facebook Client OAuth settings domain not working with query strings
I'm trying to get the Auth working with Facebook but it keeps on telling me that my redirect URL is not working.我试图让授权与 Facebook 一起工作,但它一直告诉我我的重定向 URL 不工作。
In the Valid OAuth Redirect URIs I have the following在有效的 OAuth 重定向 URI中,我有以下内容
https://localhost
The issue is that, I'm passing some additional query string to my callback, like问题是,我将一些额外的查询字符串传递给我的回调,比如
https://localhost?uuid=something&service=my_service
When attempting to Auth, I do get the request popup and then I get a redirect URL but then Facebook is telling me that the URL is not allowed.尝试进行身份验证时,我确实收到请求弹出窗口,然后收到重定向 URL,但随后 Facebook 告诉我不允许使用 URL。
If I test https://localhost?uuid=something&service=my_service
in Facebook's Redirect URI Validator it's telling me it's not valid如果我在 Facebook 的重定向 URI 验证器中测试https://localhost?uuid=something&service=my_service
它告诉我它无效
How can I add aa URL including a dynamic query string?如何添加 aa URL 包括动态查询字符串? I've tried我试过了
https://localhost*
But Facebook is telling me this is not a valid URL and won't let me save/add this URL.但是 Facebook 告诉我这不是有效的 URL,并且不允许我保存/添加这个 URL。
@ceejayoz put me on the right track, I will answer my own question, that might help someone else. @ceejayoz 让我走上正轨,我会回答我自己的问题,这可能会对其他人有所帮助。
Additional data must be passed in a state
parameter such as必须在state
参数中传递附加数据,例如
$data = json_encode($some_std_class);
$pdata = $fb_helper->getPersistentDataHandler();
$pdata->set('state', $data);
$login_url = $fb_helper->getLoginUrl($my_url, $my_permissions);
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.