AngularJS Google Oauth 400错误redirect_uri的参数值无效:不允
我正在使用Kinvey在我的AngularJS应用程序上处理Oauth,它适用于Facebook,但是当我尝试使用Google登录时,我收到400错误:
错误:invalid_request redirect_uri的参数值无效:不允许使用片段:localhost:9000 /#/ login 有没有人遇到过Google Oauth和Angular这个问题?关于如何绕过它的任何想法?该问题源于Angular路由的URL中的哈希值. 解决方法
#被称为片段标识符.错误片段不允许:表示您必须将#替换为替代,例如:
> localhost:9000 / route / login 然后与Kinvey重定向: req.request({uri: 'http://localhost:9000/route/login',method: 'GET'},function(error,response,body){ response.statusCode = 302; response.setHeader("Location","/#/login"); response.end(); } ); 以下是一些与类似问题无关的问题: > Redirect to different page url in Node.js (Not in express or other frameworks) (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |