html template: more anti-caching settings
[chrisu/seepark.git] / web / templates / seepark_web.html
1 <!DOCTYPE html>
2 <html lang="de">
3         <head>
4                 <!-- mobile first, yeah -->
5                 <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
7                 <!-- don't cache; refresh -->
8                 <meta http-equiv="Pragma" content="no-cache" />
9                 <meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
10                 <meta http-equiv="Expires" content="0" />
11                 <meta http-equiv="Refresh" content="300" />
12
13                 <!-- Load c3.css -->
14                 <link href="{{url_for('static', filename='c3.css')}}" rel="stylesheet">
15
16                 <!-- Load own css -->
17                 <link href="{{url_for('static', filename='seepark_web.css')}}" rel="stylesheet">
18
19                 <!-- Load d3.js and c3.js -->
20                 <script src="{{url_for('static', filename='d3.js')}}" charset="utf-8"></script>
21                 <script src="{{url_for('static', filename='c3.js')}}"></script>
22
23                 <title>Seepark Obsteig</title>
24         </head>
25         <body>
26                 <h1>Daten zum Seepark Obsteig</h1>
27                 <h2>Aktuelle Werte</h2>
28                 <div id="current">
29                 <p id="currentair">
30                         {% if airvalue is none %}
31                         <strong>Luft: N/A</strong>
32                         {% else %}
33                         <strong>Luft: {{ airvalue|round(1) }}°C</strong><br />
34                         <small>({{ airtime.strftime('%Y-%m-%d %H:%M') }})</small>
35                         {% endif %}
36                 </p>
37                 <p id="currentwater">
38                         <strong>Wasser: {{ watervalue|round(1) }}°C</strong><br />
39                         <small>({{ watertime.strftime('%Y-%m-%d %H:%M') }})</small>
40                 </p>
41                 </div>
42
43                 <h2>Der See</h2>
44                 <div id="chart_water_1"></div>
45                 <div id="chart_water_7"></div>
46                 <div id="chart_water_31"></div>
47                 <div id="chart_water_365"></div>
48
49                 <h2>Die Luft</h2>
50                 <div id="chart_air_1"></div>
51                 <div id="chart_air_7"></div>
52                 <div id="chart_air_31"></div>
53                 <div id="chart_air_365"></div>
54
55                 <!-- openweathermap widget -->
56                 <div id="openweathermap-widget-15"></div>
57                 <script>
58                 window.myWidgetParam ? window.myWidgetParam : window.myWidgetParam = [];
59                 window.myWidgetParam.push({
60                         id: 15,
61                         cityid: '3319578',
62                         appid: '{{ apikey }}',
63                         units: 'metric',
64                         containerid: 'openweathermap-widget-15',
65                         lang: 'de',
66                 });
67                 (function() {
68                         var script = document.createElement('script');
69                         script.async = true;
70                         script.charset = "utf-8";
71                         script.src = "//openweathermap.org/themes/openweathermap/assets/vendor/owm/js/weather-widget-generator.js";
72                         var s = document.getElementsByTagName('script')[0];
73                         s.parentNode.insertBefore(script, s);
74                 })();
75                 </script>
76
77                 <!-- Load own javascript code -->
78                 <script src="{{url_for('static', filename='seepark_web.js')}}"></script>
79
80         </body>
81 </html>