Download the PHP package decent/wechat without Composer
On this page you can find all versions of the php package decent/wechat. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download decent/wechat
More information about decent/wechat
Files in decent/wechat
Download decent/wechat
More information about decent/wechat
Files in decent/wechat
Please rate this library. Is it a good library?
Informations about the package wechat
微信企业号授权登录
安装
- 使用composer下载扩展包
composer require decent/wechat
- 在项目 config/app.php 文件中的providers数组中,添加以下代码引入服务提供器
Decent\Wechat\WechatServiceProvider::class
- 运行以下命令,将配置文件发布到config文件夹
php artisan vendor:publish
配置
企业号id - corp_id
企业号secret - corp_secret
认证回调地址 - auth_action
一个URL地址。
用户使用微信企业号登录,扫码后会重定向到这个URL,附带用户认证的code。
可在这个URL中添加认证的业务逻辑
实现提供器 - providers
认证流程需要用到以下几个实现,其中session和微信认证已有默认提供器:
- 查找用户
需要提供根据企业号成员ID获取用户model的函数 - 保存Session 用户登录时保存session,登出时销毁session
- 微信认证
认证登录页重定向回来的code,获取企业号用户ID
All versions of wechat with dependencies
PHP Build Version
Package Version
Requires
guzzlehttp/guzzle Version
^6.2
illuminate/support Version 5.0.*|5.1.*|5.2.*|5.3.*
php Version >= 5.5.30
illuminate/support Version 5.0.*|5.1.*|5.2.*|5.3.*
php Version >= 5.5.30
The package decent/wechat contains the following files
Loading the files please wait ....