From c80609be77c520c7a96edaae930b0e31d1c6a844 Mon Sep 17 00:00:00 2001 From: tping Date: Fri, 6 Aug 2021 11:38:04 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B0=8F=E7=A8=8B=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../MiniProgramController.class.php | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 Application/Admin/Controller/MiniProgramController.class.php diff --git a/Application/Admin/Controller/MiniProgramController.class.php b/Application/Admin/Controller/MiniProgramController.class.php new file mode 100644 index 000000000..0b5fff869 --- /dev/null +++ b/Application/Admin/Controller/MiniProgramController.class.php @@ -0,0 +1,31 @@ +ajaxReturn([ + 'status' => 0, + 'msg' => 'code不能为空', + ]); + } + $url = "https://api.weixin.qq.com/sns/jscode2session?appid={$this->appId}&secret={$this->secert}&js_code={$code}"; + $r = file_get_contents($url); + echo $r; + } + + +}