Hybridauth - 无法使用Windows Live登录

时间:2014-03-11 04:12:49

标签: php hybridauth windows-live

我正在开发一个简单的PHP网站,并尝试在其中集成社交登录。所以我使用了Hybridauth库。要通过Windows Live帐户登录,我在here创建了一个新应用。在重定向网址中,我输入了完整的域名,例如http://mydomain.com,因为Live在其重定向网址中不接受查询字符串

这是我的config.php

array(
    "base_url" => "http://" . $_SERVER['HTTP_HOST'] . $this->base . "/hybridauth/", 

    "providers" => array ( 

        // windows live
        "Live" => array ( 
            "enabled" => false,
            "keys"    => array ( "id" => "xxxxxxxxx", "secret" => "xxxxxxxxx" ) 
        ), 
    ),

    "debug_mode" => false,

    "debug_file" => ""
);

点击登录链接

<a href="loginwith/live" class="zocial live">Login with Windows Live</a>

我被引导到链接

https://login.live.com/err.srf?lc=1066#error=invalid_request&error_description=The%20provided%20value%20for%20the%20input%20parameter%20'redirect_uri'%20is%20not%20valid.%20The%20expected%20value%20is%20'https://login.live.com/oauth20_desktop.srf'%20or%20a%20URL%20which%20matches%20the%20redirect%20URI%20registered%20for%20this%20client%20application.

错误消息“我们无法完成您的请求Microsoft帐户遇到技术问题。请稍后再试。”

我尝试更改重定向网址,但结果相同。有人可以解决这个问题吗?

提前多多感谢!

1 个答案:

答案 0 :(得分:0)

试试这个:

"enabled" => true,
相关问题