修改微信分享bug

master
ELF 5 years ago
parent 6679462492
commit c054595a94

@ -42,7 +42,13 @@ class HomeController extends Controller
$secret = 'd3219c70a45c5e1954be4608b288d38b';
$tokenUrl = 'https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=' . $appid . '&secret=' . $secret;
$content = file_get_contents(RUNTIME_PATH . 'Data/wechat_ticket');
$tempDataDir = RUNTIME_PATH . 'Data';
if(!is_dir($tempDataDir)) {
@mkdir($tempDataDir);
}
$content = file_get_contents($tempDataDir . '/wechat_ticket');
$ticketData = null;
if ($content) {
$ticketData = json_decode($content, true);

Loading…
Cancel
Save