dongwei2882 2014-02-04 16:52
浏览 86

Gmail登录我的网站和变更用户的电子邮件ID

I want to have gmail login for users on my web portal. In addition, I want to store their email ids and check them to allow them to alter data in the portal. (i.e. Only users with email ids with @mycollege.ac.in will be allowed). And only the user who has filled up a form to input his data, will be able to modify or remove it.)

I want to have gmail login so it becomes easy for users. Also, if user is already logged in with gmail, he will be directly allowed to input data on the portal.

I have spent much time trying to google how to do this and I have only gotten as far as having a gmail login button on the site with openid. Nothing about storing the email id or automatically logging in. Also, the code of those pages is very difficult to understand for me.

I am new in PHP. I only have basic knowledge of MySQL and PHP. So can anyone please explain how to do or what to use? Or perhaps some link to a page that explains it simply? ( I have already visited https://developers.google.com/accounts/docs/OpenID?csw=1 but still I am stuck.)

  • 写回答

1条回答 默认 最新

  • duanqian1888 2014-02-05 09:21
    关注

    I think you are looking something like this -> http://www.phpgang.com/how-to-login-with-google-account-oauth_231.html

    On this example, they do a login with Google account and get email and image of the user profile..

    I didn't test the code, it was the first result when i google about it...

    评论

报告相同问题?

悬赏问题

  • ¥15 想问一下树莓派接上显示屏后出现如图所示画面,是什么问题导致的
  • ¥100 嵌入式系统基于PIC16F882和热敏电阻的数字温度计
  • ¥15 cmd cl 0x000007b
  • ¥20 BAPI_PR_CHANGE how to add account assignment information for service line
  • ¥500 火焰左右视图、视差(基于双目相机)
  • ¥100 set_link_state
  • ¥15 虚幻5 UE美术毛发渲染
  • ¥15 CVRP 图论 物流运输优化
  • ¥15 Tableau online 嵌入ppt失败
  • ¥100 支付宝网页转账系统不识别账号