leslie / wx_token
颁发微信token"
v1.0
2019-01-20 13:33 UTC
Requires
- php: >5.6
This package is auto-updated.
Last update: 2024-12-22 00:04:15 UTC
README
微信分享token
使用方法:
composer require leslie/wx_token
use Leslie\WxToken\GetWxToken;
require ('vendor/autoload.php');
$appId = "xxxxxxxxxx";
$secret = "xxxxxxxxxxxxxxxxx";
$url = "xxxxxxxxxxxxxxxxxxxxxxxxx";
$timestamp = time();
$nonceStr = GetWxToken::getAccessToken($appId,$secret);
$access = $nonceStr->access_token;
$getTicket = GetWxToken::getTicket($access);
$ticket = $getTicket->ticket;
$res = GetWxToken::getSignature($url,$ticket);
var_dump($res);