mirror of
https://github.com/w7corp/easywechat.git
synced 2025-02-02 02:34:22 +00:00
Created 网页授权 (markdown)
parent
4904ad6756
commit
96c519b683
24
网页授权.md
Normal file
24
网页授权.md
Normal file
@ -0,0 +1,24 @@
|
||||
```php
|
||||
$wechat->auth;
|
||||
```
|
||||
|
||||
+ 生成授权链接
|
||||
|
||||
```php
|
||||
// 生成并返回
|
||||
$wechat->auth->url($to, $state, $scope);
|
||||
// 直接跳转
|
||||
$wechat->auth->redirect($to, $state, $scope); 直接跳转
|
||||
```
|
||||
|
||||
+ 判断是否已经授权
|
||||
|
||||
```php
|
||||
$wechat->auth->authorized();
|
||||
```
|
||||
|
||||
+ 获取授权用户
|
||||
|
||||
```php
|
||||
$wechat->auth->user();
|
||||
```
|
Loading…
Reference in New Issue
Block a user