From d510c38811c0f1fa67ebfe81451cb32aef1cf826 Mon Sep 17 00:00:00 2001 From: tping Date: Tue, 24 Aug 2021 17:40:50 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B0=8F=E7=A8=8B=E5=BA=8F=E4=BA=8C=E7=BB=B4?= =?UTF-8?q?=E7=A0=81=E6=8E=A8=E5=B9=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Qrcode/Controller/JumpController.class.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Application/Qrcode/Controller/JumpController.class.php b/Application/Qrcode/Controller/JumpController.class.php index 57331c947..f0f86a435 100644 --- a/Application/Qrcode/Controller/JumpController.class.php +++ b/Application/Qrcode/Controller/JumpController.class.php @@ -57,8 +57,9 @@ class JumpController extends HomeController // MiniTop 二维码推广 public function getImgs() { - $backgroundImg = 'http://'.$_SERVER['HTTP_HOST']."/Public/Qrcode/images/b.png"; - $qrCodeImg = 'http://'.$_SERVER['HTTP_HOST']."/Public/Qrcode/images/qrcode.png"; + $isHttps = is_https(); + $backgroundImg = ($isHttps? 'https://': 'http://').$_SERVER['HTTP_HOST']."/Public/Qrcode/images/b.png"; + $qrCodeImg = ($isHttps? 'https://': 'http://').$_SERVER['HTTP_HOST']."/Public/Qrcode/images/qrcode.png"; $id = I('request.id', 0); if (!$id || !is_numeric($id)) { $this->ajaxReturn([