-
Notifications
You must be signed in to change notification settings - Fork 1
/
footer.php
54 lines (50 loc) · 1.12 KB
/
footer.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
<?php echo "<script src='".PROJECT_PATH."/resources/jquery/jquery-qrcode.min.js'></script>"; ?>
<script type="text/javascript">
function show_qr(url) {
$('#qr_code').empty().qrcode({
render: 'canvas',
minVersion: 6,
maxVersion: 40,
ecLevel: 'H',
size: 650,
radius: 0.2,
quiet: 6,
background: '#fff',
mode: 4,
mSize: 0.2,
mPosX: 0.5,
mPosY: 0.5,
text: url,
});
$('#qr_code_container').fadeIn(400);
}
function copy(data) {
navigator.clipboard.writeText(data).then(() => {
// TODO: positive feedback
}).catch((e) => {
// TODO: negative feedback
});
}
</script>
<style type="text/css">
#qr_code_container {
z-index: 999999;
position: absolute;
left: 0;
top: 0;
right: 0;
bottom: 0;
text-align: center;
vertical-align: middle;
}
#qr_code {
display: block;
width: 650px;
height: 650px;
-webkit-box-shadow: 0px 1px 20px #888;
-moz-box-shadow: 0px 1px 20px #888;
box-shadow: 0px 1px 20px #888;
}
</style>
<?php
require_once "resources/footer.php";