Browse Source

add qr image

master
filesite 5 months ago
parent
commit
f42acce052
  1. 5
      themes/beauty/views/layout/main.php
  2. 1
      www/css/beauty.css
  3. 10
      www/js/beauty.js
  4. 1
      www/js/qrcode.min.js

5
themes/beauty/views/layout/main.php

@ -31,6 +31,10 @@ require_once __DIR__ . '/../../../../plugins/Html.php';
<!-- 尾部网站信息 --> <!-- 尾部网站信息 -->
<footer class="web_info vercenter"> <footer class="web_info vercenter">
<div class="qrcode text-center">
<p>用手机扫码打开</p>
<div id="qrimg"></div>
</div>
<p> <p>
Copyright <span>&copy;2022</span> Copyright <span>&copy;2022</span>
by <a href="https://filesite.io/" target="_blank">FileSite.io</a> by <a href="https://filesite.io/" target="_blank">FileSite.io</a>
@ -92,6 +96,7 @@ eof;
<script src="/js/bootstrap.min.js"></script> <script src="/js/bootstrap.min.js"></script>
<script src="/js/lazyload.js"></script> <script src="/js/lazyload.js"></script>
<script src="/js/fubox.min.js"></script> <script src="/js/fubox.min.js"></script>
<script src="/js/qrcode.min.js"></script>
<script src="/js/beauty.js?v<?= Html::getStaticFileVersion('beauty.js', 'js') ?>"></script> <script src="/js/beauty.js?v<?= Html::getStaticFileVersion('beauty.js', 'js') ?>"></script>
<?php echo Html::getGACode(); ?> <?php echo Html::getGACode(); ?>
</body> </body>

1
www/css/beauty.css

@ -102,6 +102,7 @@ a:link{text-decoration:none}
.lampshow .text_dark{color:#808080} .lampshow .text_dark{color:#808080}
.lampshow .text_dark a{color:#f4f7fd} .lampshow .text_dark a{color:#f4f7fd}
#qrimg{width:160px;height:160px;margin:0 auto 20px auto;background-color:#FFF;padding:5px;border:1px solid #EEE;border-radius:5px}
@media screen and (max-width: 1199px) { @media screen and (max-width: 1199px) {
.im_item { .im_item {

10
www/js/beauty.js

@ -133,4 +133,14 @@ if ($('#image_site').get(0)) {
}); });
} }
//二维码显示
if ($('#qrimg').length > 0 && typeof(QRCode) != 'undefined') {
var qrcode = new QRCode("qrimg", {
text: location.href,
colorDark : "#000000",
colorLight : "#ffffff",
correctLevel : QRCode.CorrectLevel.H
});
}
} }

1
www/js/qrcode.min.js vendored

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save