如何在我们与谷歌帐户的网站我们的用户进行身份验证

问题描述:

如何进行身份验证使用谷歌账户在我们的网站的用户。我希望用户被重新定向到谷歌登录页面,然后重定向他到我的网站。我想在PHP中,这实现。

How to authenticate a user using google account in our website. i want a user to be redirect to google login page and then redirect him to my website. I want this implementation in PHP.

认证可以使用OpenID来完成。一份详细的文件有没有在谷歌的http:// code。 google.com/apis/accounts/docs/OpenID.html

Authentication can be done using OpenID. A detailed document is there in Google http://code.google.com/apis/accounts/docs/OpenID.html

更新:链接已经被日由谷歌pcated $ P $。请参考以下链接上使用谷歌自己的的OAuth2 API文档,而不是困扰了这么多为读书库因为他们是非常复杂,最终可能会失去焦点。

Update: The links have been deprecated by Google. Refer to the following links to use Google's own OAuth2 API documentation instead of bothering so much into reading the libraries because they are very complicated and may end up losing focus.