-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.php
75 lines (68 loc) · 2.94 KB
/
index.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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
<!doctype html>
<html lang="hu">
<head>
<title>BKK Ambient Display</title><meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="BKK Ambient Display">
<meta name="theme-color" content="#000000">
<link href="https://fonts.googleapis.com/css?family=Alata|Lato&display=swap" rel="stylesheet">
<script src="https://code.jquery.com/jquery-3.4.1.min.js" integrity="sha256-CSXorXvZcTkaix6Yvo6HppcZGetbYMGWSFlBw8HfCJo=" crossorigin="anonymous"></script>
<link rel="stylesheet" href="main.css?v=<?=time();?>">
<script src="js/main.js?v=<?=time();?>"></script>
<script src="js/time.js?v=<?=time();?>"></script>
<script src="js/bkk.js?v=<?=time();?>"></script>
<script src="js/weather.js?v=<?=time();?>"></script>
<link rel="icon" type="image/png" src="img/bad-icon-144.png">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta name="apple-mobile-web-app-title" content="BKK Ambient Display">
<link rel="apple-touch-icon" href="img/bad-icon-192.png">
<link rel="manifest" href="manifest.json">
</head>
<body>
<div class="fs-div"></div>
<div class="time">
<div id="clock"></div>
<div id="date"></div>
<div id="weather">
<div class="info">
<p>Getting weather info</p>
</div>
</div>
</div><div id="bkk-container">
<div class="ADFL-update dyn-timestamp"></div>
</div>
<script>
var global = {
config: {
showSecs: false
},
DOMs: {
clock: $("#clock"),
date: $("#date"),
ADFLContainer: $("#bkk-container"),
ADFLElem: null,
loader: null,
},
time: {},
clientLoc: {},
timeFreq: 500,
srvTimeFreq: 10*60*1000, //10 min
locationFreq: 30*1000, //30 sec
weatherFreq: 15*60*1000, //15 min
delay: 0
}
$(".fs-div").on('touchstart',function(){ toggleFullScreen(); });
global.DOMs.ADFLElem = $("<div>").addClass("ADFL-elem").append($("<div>").addClass("stop-header")).append($("<div>").addClass("stop-body"));
global.time.humanRead = humanRead;
global.time.isPast = isPast;
updateServerTime(global);
updateTime(global);
updateLocation(global);
updateADFL(global);
updateWeather(global);
updateLayout();
$(window).resize(updateLayout);
</script>
</body>
</html>