Heim  >  Artikel  >  Backend-Entwicklung  >  thinkPHP和微信公众号实现的扫码登录网站的功能

thinkPHP和微信公众号实现的扫码登录网站的功能

WBOY
WBOYOriginal
2016-07-25 08:43:593400Durchsuche
用thinkPHP和微信公众号提供的扫描带参数的二维码功能来实现用户登录网站的功能,这样省去了用户注册,输入账号等繁琐过程,提高了用户体验,并且能给微信公众号带来一定粉丝,今天在这里给大家分享:怎么使用thinkPHP和微信公众号提供的扫描带参数的二维码事件机制,实现登录网站的功能。可在onethink中使用,具体请看:http://vote.wucheshuedu.com/index.php?s=/Home/Article/detail/id/28.html thinkPHP和微信公众号实现的扫码登录网站的功能 thinkPHP和微信公众号实现的扫码登录网站的功能 thinkPHP和微信公众号实现的扫码登录网站的功能 thinkPHP和微信公众号实现的扫码登录网站的功能
  1. /* 关注微信公众号登录 */
  2. public function login(){
  3. $src = get_qrcode(time(), 2);
  4. $this->assign('src', $src);
  5. $this->assign('scene_id', $_SESSION['scene_id']);
  6. $this->display();
  7. }
复制代码
thinkPHP


Stellungnahme:
Der Inhalt dieses Artikels wird freiwillig von Internetnutzern beigesteuert und das Urheberrecht liegt beim ursprünglichen Autor. Diese Website übernimmt keine entsprechende rechtliche Verantwortung. Wenn Sie Inhalte finden, bei denen der Verdacht eines Plagiats oder einer Rechtsverletzung besteht, wenden Sie sich bitte an admin@php.cn