master
handlebars 247 lines 9.25 KB
Raw
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2 <html lang="en">
3 <head>
4 <meta http-equiv="X-UA-Compatible" content="IE=edge" />
5 <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
6 <meta name="viewport" content="user-scalable=1.0,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0" />
7 <meta name="apple-mobile-web-app-capable" content="yes" />
8 <meta name="format-detection" content="telephone=no" />
9 <meta name="robots" content="noindex,nofollow" />
10 <link type="text/css" href="/styles/style.css" media="screen" rel="stylesheet" title="CSS" />
11 {{{customCSSTags}}}
12 <link rel="apple-touch-icon" href="/favicon-303x303.png" />
13 {{{customJSTags}}}
14 <title>{{{title}}}</title>
15 <style nonce="{{{cspNonce}}}">
16 #xbody {
17 overflow: hidden;
18 }
19
20 #masthead {
21 background: url(logo.png) 0px 0px;
22 background-color: #036;
23 background-repeat: no-repeat;
24 height: 66px;
25 width: 100%;
26 overflow: hidden;
27 }
28
29 #title1 {
30 float: left;
31 text-shadow: 1px 1px 2px #000;
32 }
33
34 #title2 {
35 float: left;
36 height: 66px;
37 color: #c8c8c8;
38 padding-left: 16px;
39 padding-top: 7px;
40 }
41
42 #title2a {
43 font-size: 46px;
44 font-family: Arial, Helvetica, sans-serif;
45 text-shadow: 1px 1px 2px #000;
46 }
47
48 #title3 {
49 float: left;
50 height: 66px;
51 color: #c8c8c8;
52 padding-left: 5px;
53 padding-top: 14px;
54 }
55
56 #title3a {
57 font-size: 14px;
58 font-family: Arial, Helvetica, sans-serif;
59 text-shadow: 1px 1px 2px #000;
60 }
61
62 #footerLeft {
63 text-align: left;
64 }
65
66 #footerRight {
67 text-align: right;
68 }
69
70 #topbar {
71 height: 24px;
72 position: relative;
73 }
74
75 #page_leftbar_div {
76 height: 16px;
77 }
78
79 #uiMenu {
80 }
81
82 #text1 {
83 text-align: center;
84 padding-top: 30px;
85 font-size: 200px;
86 font-family: Arial;
87 color: #bbb;
88 }
89
90 #text2 {
91 text-align: center;
92 font-size: 20px;
93 font-family: Arial;
94 color: #999;
95 }
96
97 #text3 {
98 text-align: center;
99 padding-top: 20px;
100 font-size: 20px;
101 font-family: Arial;
102 color: #999;
103 }
104
105 #column_l {
106 max-height: calc(100vh - 135px);
107 overflow-y: auto;
108 }
109 </style>
110 </head>
111 <body id="xbody">
112 <div id="container">
113 <!-- Begin Masthead -->
114 <div id="masthead" class=noselect>
115 <div id="title1">{{{titlehtml}}}</div>
116 <div id="title2">
117 <strong><font id="title2a">{{{title1}}}</font></strong>
118 </div>
119 <div id="title3">
120 <strong><font id="title3a">{{{title2}}}</font></strong>
121 </div>
122 </div>
123 <div id="page_leftbar">
124 <div id="page_leftbar_div"></div>
125 </div>
126 <div id=topbar class="noselect style3">
127 <div id=uiMenuButton title="User interface selection">
128 &diams;
129 <div id=uiMenu>
130 <div id=uiViewButton1 class=uiSelector title="Left bar interface"><div class="uiSelector1"></div></div>
131 <div id=uiViewButton2 class=uiSelector title="Top bar interface"><div class="uiSelector2"></div></div>
132 <div id=uiViewButton3 class=uiSelector title="Fixed width interface"><div class="uiSelector3"></div></div>
133 <div id=uiViewButton4 class=uiSelector title="Toggle night mode"><div class="uiSelector4"></div></div>
134 </div>
135 </div>
136 </div>
137 <div id="column_l">
138 <div id="text1"><b>404</b></div>
139 <div id="text2">This page does not exist</div>
140 <div id="text3"><a href="/" style="text-decoration:none"><b>Go to main site</b></a></div>
141 </div>
142 <div id="footer">
143 <table cellpadding="0" cellspacing="10" style="width: 100%">
144 <tr>
145 <td id="footerLeft"></td>
146 <td id="footerRight"><a href="/">Back</a></td>
147 </tr>
148 </table>
149 </div>
150 </div>
151 <script nonce="{{{cspNonce}}}">
152 'use strict';
153 var random = '{{{randomlength}}}' // Random length string for BREACH mitigation
154 var uiMode = parseInt(getstore('uiMode', 1));
155 var webPageStackMenu = false;
156 var webPageFullScreen = true;
157 var nightMode = (getstore('_nightMode', '0') == '1');
158 var menuVisible = false;
159 QV('uiMenu', menuVisible);
160 if (nightMode) { QC('xbody').add('night'); } else { QC('xbody').remove('night'); }
161
162 // Setup handlers
163 Q('uiMenuButton').onclick = showUserInterfaceSelectMenu;
164 Q('uiViewButton1').onclick = function () { userInterfaceSelectMenu(1); }
165 Q('uiViewButton2').onclick = function () { userInterfaceSelectMenu(2); }
166 Q('uiViewButton3').onclick = function () { userInterfaceSelectMenu(3); }
167 Q('uiViewButton4').onclick = toggleNightMode;
168
169 var terms = '{{{terms}}}';
170 if (terms != '') { QH('column_l', decodeURIComponent(terms)); }
171 QV('column_l', true);
172 userInterfaceSelectMenu();
173
174 // Toggle user interface menu
175 function showUserInterfaceSelectMenu() {
176 Q('uiViewButton1').classList.remove('uiSelectorSel');
177 Q('uiViewButton2').classList.remove('uiSelectorSel');
178 Q('uiViewButton3').classList.remove('uiSelectorSel');
179 Q('uiViewButton4').classList.remove('uiSelectorSel');
180 try { Q('uiViewButton' + uiMode).classList.add('uiSelectorSel'); } catch (ex) { }
181 menuVisible = !menuVisible;
182 QV('uiMenu', menuVisible);
183 if (nightMode) { Q('uiViewButton4').classList.add('uiSelectorSel'); }
184 }
185
186 function userInterfaceSelectMenu(s) {
187 if (s) { uiMode = s; putstore('uiMode', uiMode); }
188 webPageFullScreen = (uiMode < 3);
189 webPageStackMenu = true;//(uiMode > 1);
190 toggleFullScreen(0);
191 toggleStackMenu(0);
192 QC('column_l').add('room4submenu');
193 }
194
195 function toggleNightMode() {
196 nightMode = !nightMode;
197 if (nightMode) { QC('xbody').add('night'); } else { QC('xbody').remove('night'); }
198 putstore('_nightMode', nightMode ? '1' : '0');
199 }
200
201 // Toggle the web page to full screen
202 function toggleFullScreen(toggle) {
203 if (toggle === 1) { webPageFullScreen = !webPageFullScreen; putstore('webPageFullScreen', webPageFullScreen); }
204 var hide = 0;
205 //if (args.hide) { hide = parseInt(args.hide); }
206 if (webPageFullScreen == false) {
207 QC('xbody').remove('menu_stack');
208 QC('xbody').remove('fullscreen');
209 QC('xbody').remove('arg_hide');
210 //if (xxcurrentView >= 10) QC('column_l').add('room4submenu');
211 //QV('UserDummyMenuSpan', false);
212 //QV('page_leftbar', false);
213 } else {
214 QC('xbody').add('fullscreen');
215 if (hide & 16) QC('xbody').add('arg_hide'); // This is replacement for QV('page_leftbar', !(hide & 16));
216 //QV('UserDummyMenuSpan', (xxcurrentView < 10) && webPageFullScreen);
217 //QV('page_leftbar', true);
218 }
219 QV('xbody', true);
220 }
221
222 // If FullScreen, toggle menu to be horisontal or vertical
223 function toggleStackMenu(toggle) {
224 if (webPageFullScreen == true) {
225 if (toggle === 1) {
226 webPageStackMenu = !webPageStackMenu;
227 putstore('webPageStackMenu', webPageStackMenu);
228 }
229 if (webPageStackMenu == false) {
230 QC('xbody').remove('menu_stack');
231 } else {
232 QC('xbody').add('menu_stack');
233 //if (xxcurrentView >= 10) QC('column_l').remove('room4submenu');
234 }
235 }
236 }
237
238 function putstore(name, val) { try { if (typeof (localStorage) === 'undefined') return; localStorage.setItem(name, val); } catch (e) { } }
239 function getstore(name, val) { try { if (typeof (localStorage) === 'undefined') return val; var v = localStorage.getItem(name); if ((v == null) || (v == null)) return val; return v; } catch (e) { return val; } }
240 function Q(x) { return document.getElementById(x); } // "Q"
241 function QS(x) { try { return Q(x).style; } catch (x) { } } // "Q" style
242 function QV(x, y) { try { QS(x).display = (y ? '' : 'none'); } catch (ex) { console.log(ex); } } // "Q" visible
243 function QH(x, y) { Q(x).innerHTML = y; } // "Q" html
244 function QC(x) { try { return Q(x).classList; } catch (x) { } } // "Q" class
245 </script>
246 </body>
247 </html>