-
Notifications
You must be signed in to change notification settings - Fork 0
/
3.html
118 lines (105 loc) · 3.26 KB
/
3.html
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>QR Code</title>
<link rel="icon" type="jpg" href="https://upload.wikimedia.org/wikipedia/en/thumb/6/61/Emblem_of_Telangana.svg/800px-Emblem_of_Telangana.svg.png">
<style>
body {
font-family: 'Arial', sans-serif;
display: flex;
flex-direction: column;
align-items: center;
height: 100vh;
margin: 0;
}
#header {
background-color: #0c76af;
padding: 15px;
text-align: center;
width: 100%;
color: #fff;
display: flex;
align-items: center;
justify-content: center;
}
#header img {
border-radius: 50%;
width: 100px;
height: 100px;
margin-right: 10px;
}
#header p {
font-size: 18px;
margin: 0;
}
#qr-container {
text-align: center;
margin-top: 20px;
}
#qr-code {
width: 150px;
height: 150px;
}
#scan-text {
font-size: 18px;
margin-top: 20px;
}
#download-button {
background-color: #007bff;
color: #fff;
border: none;
padding: 10px 20px;
cursor: pointer;
}
.footer {
background-color: #3a3a3a;
color: #fff;
padding: 10px 0;
text-align: center;
font-size: 14px;
position: absolute;
bottom: 0;
width: 100%;
margin-top: 20px;
}
.footer a {
color: rgb(0, 110, 255);
}
</style>
</head>
<body>
<div id="header">
<img src="https://upload.wikimedia.org/wikipedia/en/thumb/6/61/Emblem_of_Telangana.svg/800px-Emblem_of_Telangana.svg.png" alt="Government of Telangana State Transport Department Logo">
<p>Government of Telangana State Transport Department</p>
</div>
<div>
<h1>Road safety and Emergency </h1>
</div>
<div id="qr-container">
<img id="qr-code" src="qr.png" alt="QR Code">
<p id="scan-text">Scan this QR</p>
<p style="font-size: larger;">[ AND ]</p>
</div>
<div id="number-plate">
<img src="num-plate.jpeg" alt="number-plate" width="300" height="200"><br>
<button id="download-button">Download Number Plate</button>
</div>
<script>
const image = document.querySelector('#number-plate img');
const downloadButton = document.querySelector('#download-button');
image.addEventListener('click', () => {
downloadButton.style.display = 'block';
});
downloadButton.addEventListener('click', () => {
const link = document.createElement('a');
link.href = image.src;
link.download = 'number-plate.jpeg';
document.body.appendChild(link);
link.click();
document.body.removeChild(link);
});
</script>
</body>
</html>