@@ -14,31 +14,31 @@ discard block |
||
14 | 14 | { |
15 | 15 | $coords = explode(',',$_GET['coord']); |
16 | 16 | if ((isset($_COOKIE['show_GroundStation']) && $_COOKIE['show_GroundStation'] == 'true') |
17 | - || (!isset($_COOKIE['show_GroundStation']) && (!isset($globalMapGroundStation) || $globalMapGroundStation === TRUE))) { |
|
17 | + || (!isset($_COOKIE['show_GroundStation']) && (!isset($globalMapGroundStation) || $globalMapGroundStation === TRUE))) { |
|
18 | 18 | //$spotter_array = $Source->getAllLocationInfo(); |
19 | 19 | $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('gs')); |
20 | 20 | } |
21 | 21 | if ((isset($_COOKIE['show_WeatherStation']) && $_COOKIE['show_WeatherStation'] == 'true') |
22 | - || (!isset($_COOKIE['show_WeatherStation']) && (!isset($globalMapWeatherStation) || $globalMapWeatherStation === TRUE))) { |
|
22 | + || (!isset($_COOKIE['show_WeatherStation']) && (!isset($globalMapWeatherStation) || $globalMapWeatherStation === TRUE))) { |
|
23 | 23 | $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('wx')); |
24 | 24 | } |
25 | 25 | if ((isset($_COOKIE['show_Lightning']) && $_COOKIE['show_Lightning'] == 'true') |
26 | - || (!isset($_COOKIE['show_Lightning']) && (!isset($globalMapLightning) || $globalMapLightning === TRUE))) { |
|
26 | + || (!isset($_COOKIE['show_Lightning']) && (!isset($globalMapLightning) || $globalMapLightning === TRUE))) { |
|
27 | 27 | $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('lightning')); |
28 | 28 | } |
29 | 29 | $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('')); |
30 | 30 | } else { |
31 | 31 | if ((isset($_COOKIE['show_GroundStation']) && $_COOKIE['show_GroundStation'] == 'true') |
32 | - || (!isset($_COOKIE['show_GroundStation']) && (!isset($globalMapGroundStation) || $globalMapGroundStation === TRUE))) { |
|
32 | + || (!isset($_COOKIE['show_GroundStation']) && (!isset($globalMapGroundStation) || $globalMapGroundStation === TRUE))) { |
|
33 | 33 | //$spotter_array = $Source->getAllLocationInfo(); |
34 | 34 | $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('gs')); |
35 | 35 | } |
36 | 36 | if ((isset($_COOKIE['show_WeatherStation']) && $_COOKIE['show_WeatherStation'] == 'true') |
37 | - || (!isset($_COOKIE['show_WeatherStation']) && (!isset($globalMapWeatherStation) || $globalMapWeatherStation === TRUE))) { |
|
37 | + || (!isset($_COOKIE['show_WeatherStation']) && (!isset($globalMapWeatherStation) || $globalMapWeatherStation === TRUE))) { |
|
38 | 38 | $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('wx')); |
39 | 39 | } |
40 | 40 | if ((isset($_COOKIE['show_Lightning']) && $_COOKIE['show_Lightning'] == 'true') |
41 | - || (!isset($_COOKIE['show_Lightning']) && (!isset($globalMapLightning) || $globalMapLightning === TRUE))) { |
|
41 | + || (!isset($_COOKIE['show_Lightning']) && (!isset($globalMapLightning) || $globalMapLightning === TRUE))) { |
|
42 | 42 | $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('lightning')); |
43 | 43 | } |
44 | 44 | $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('')); |
@@ -53,7 +53,7 @@ discard block |
||
53 | 53 | date_default_timezone_set('UTC'); |
54 | 54 | //waypoint plotting |
55 | 55 | $output .= '{"type": "Feature",'; |
56 | - $output .= '"properties": {'; |
|
56 | + $output .= '"properties": {'; |
|
57 | 57 | $output .= '"id": "'.$spotter_item['id'].'",'; |
58 | 58 | $output .= '"location_id": "'.$spotter_item['location_id'].'",'; |
59 | 59 | $output .= '"name": "'.$spotter_item['name'].'",'; |
@@ -71,13 +71,13 @@ discard block |
||
71 | 71 | if (isset($weather['temp'])) $output.= '"temp": "'.$weather['temp'].'",'; |
72 | 72 | } |
73 | 73 | $output .= '"image_thumb": "'.$spotter_item['image_thumb'].'"'; |
74 | - $output .= '},'; |
|
75 | - $output .= '"geometry": {'; |
|
74 | + $output .= '},'; |
|
75 | + $output .= '"geometry": {'; |
|
76 | 76 | $output .= '"type": "Point",'; |
77 | 77 | $output .= '"coordinates": ['; |
78 | - $output .= $spotter_item['longitude'].', '.$spotter_item['latitude']; |
|
78 | + $output .= $spotter_item['longitude'].', '.$spotter_item['latitude']; |
|
79 | 79 | $output .= ']'; |
80 | - $output .= '}'; |
|
80 | + $output .= '}'; |
|
81 | 81 | $output .= '},'; |
82 | 82 | } |
83 | 83 | $output = substr($output, 0, -1); |
@@ -12,43 +12,43 @@ discard block |
||
12 | 12 | if (!isset($globalDemo)) { |
13 | 13 | if (isset($_GET['coord'])) |
14 | 14 | { |
15 | - $coords = explode(',',$_GET['coord']); |
|
15 | + $coords = explode(',', $_GET['coord']); |
|
16 | 16 | if ((isset($_COOKIE['show_GroundStation']) && $_COOKIE['show_GroundStation'] == 'true') |
17 | 17 | || (!isset($_COOKIE['show_GroundStation']) && (!isset($globalMapGroundStation) || $globalMapGroundStation === TRUE))) { |
18 | 18 | //$spotter_array = $Source->getAllLocationInfo(); |
19 | - $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('gs')); |
|
19 | + $spotter_array = array_merge($spotter_array, $Source->getLocationInfoByType('gs')); |
|
20 | 20 | } |
21 | 21 | if ((isset($_COOKIE['show_WeatherStation']) && $_COOKIE['show_WeatherStation'] == 'true') |
22 | 22 | || (!isset($_COOKIE['show_WeatherStation']) && (!isset($globalMapWeatherStation) || $globalMapWeatherStation === TRUE))) { |
23 | - $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('wx')); |
|
23 | + $spotter_array = array_merge($spotter_array, $Source->getLocationInfoByType('wx')); |
|
24 | 24 | } |
25 | 25 | if ((isset($_COOKIE['show_Lightning']) && $_COOKIE['show_Lightning'] == 'true') |
26 | 26 | || (!isset($_COOKIE['show_Lightning']) && (!isset($globalMapLightning) || $globalMapLightning === TRUE))) { |
27 | - $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('lightning')); |
|
27 | + $spotter_array = array_merge($spotter_array, $Source->getLocationInfoByType('lightning')); |
|
28 | 28 | } |
29 | - $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('')); |
|
29 | + $spotter_array = array_merge($spotter_array, $Source->getLocationInfoByType('')); |
|
30 | 30 | } else { |
31 | 31 | if ((isset($_COOKIE['show_GroundStation']) && $_COOKIE['show_GroundStation'] == 'true') |
32 | 32 | || (!isset($_COOKIE['show_GroundStation']) && (!isset($globalMapGroundStation) || $globalMapGroundStation === TRUE))) { |
33 | 33 | //$spotter_array = $Source->getAllLocationInfo(); |
34 | - $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('gs')); |
|
34 | + $spotter_array = array_merge($spotter_array, $Source->getLocationInfoByType('gs')); |
|
35 | 35 | } |
36 | 36 | if ((isset($_COOKIE['show_WeatherStation']) && $_COOKIE['show_WeatherStation'] == 'true') |
37 | 37 | || (!isset($_COOKIE['show_WeatherStation']) && (!isset($globalMapWeatherStation) || $globalMapWeatherStation === TRUE))) { |
38 | - $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('wx')); |
|
38 | + $spotter_array = array_merge($spotter_array, $Source->getLocationInfoByType('wx')); |
|
39 | 39 | } |
40 | 40 | if ((isset($_COOKIE['show_Lightning']) && $_COOKIE['show_Lightning'] == 'true') |
41 | 41 | || (!isset($_COOKIE['show_Lightning']) && (!isset($globalMapLightning) || $globalMapLightning === TRUE))) { |
42 | - $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('lightning')); |
|
42 | + $spotter_array = array_merge($spotter_array, $Source->getLocationInfoByType('lightning')); |
|
43 | 43 | } |
44 | - $spotter_array = array_merge($spotter_array,$Source->getLocationInfoByType('')); |
|
44 | + $spotter_array = array_merge($spotter_array, $Source->getLocationInfoByType('')); |
|
45 | 45 | } |
46 | 46 | } |
47 | 47 | |
48 | 48 | $output = '{"type": "FeatureCollection","features": ['; |
49 | 49 | if (!empty($spotter_array) && count($spotter_array) > 0) |
50 | 50 | { |
51 | - foreach($spotter_array as $spotter_item) |
|
51 | + foreach ($spotter_array as $spotter_item) |
|
52 | 52 | { |
53 | 53 | date_default_timezone_set('UTC'); |
54 | 54 | //waypoint plotting |
@@ -67,8 +67,8 @@ discard block |
||
67 | 67 | $output .= '"icon": "'.$globalURL.'/images/'.$spotter_item['logo'].'",'; |
68 | 68 | $output .= '"type": "'.$spotter_item['type'].'",'; |
69 | 69 | if ($spotter_item['type'] == 'wx') { |
70 | - $weather = json_decode($spotter_item['description'],true); |
|
71 | - if (isset($weather['temp'])) $output.= '"temp": "'.$weather['temp'].'",'; |
|
70 | + $weather = json_decode($spotter_item['description'], true); |
|
71 | + if (isset($weather['temp'])) $output .= '"temp": "'.$weather['temp'].'",'; |
|
72 | 72 | } |
73 | 73 | $output .= '"image_thumb": "'.$spotter_item['image_thumb'].'"'; |
74 | 74 | $output .= '},'; |
@@ -80,7 +80,7 @@ discard block |
||
80 | 80 | $output .= '}'; |
81 | 81 | $output .= '},'; |
82 | 82 | } |
83 | - $output = substr($output, 0, -1); |
|
83 | + $output = substr($output, 0, -1); |
|
84 | 84 | } |
85 | 85 | $output .= ']}'; |
86 | 86 |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | <?php }; if (isset($globalTracker) && $globalTracker) { ?><td><div id="ibxtracker"><h4><?php echo _("Trackers Detected"); ?></h4><br /><i class="fa fa-spinner fa-pulse fa-fw"></i></div></td><?php } ?> |
46 | 46 | </tr></table></div> |
47 | 47 | <?php |
48 | - if ((!isset($_COOKIE['MapFormat']) && isset($globalMap3Ddefault) && $globalMap3Ddefault) || (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d')) { |
|
48 | + if ((!isset($_COOKIE['MapFormat']) && isset($globalMap3Ddefault) && $globalMap3Ddefault) || (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d')) { |
|
49 | 49 | |
50 | 50 | ?> |
51 | 51 | <script src="<?php echo $globalURL; ?>/js/map.3d.js.php"></script> |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | <script src="<?php echo $globalURL; ?>/js/map-marine.3d.js.php"></script> |
66 | 66 | <?php |
67 | 67 | } |
68 | - } |
|
68 | + } |
|
69 | 69 | ?> |
70 | 70 | |
71 | 71 | <div id="sidebar" class="sidebar collapsed"> |
@@ -76,34 +76,34 @@ discard block |
||
76 | 76 | <li><a href="#" onclick="getUserLocation(); return false;" title="<?php echo _("Plot your Location"); ?>"><i class="fa fa-map-marker"></i></a></li> |
77 | 77 | <li><a href="#" onclick="getCompassDirection(); return false;" title="<?php echo _("Compass Mode"); ?>"><i class="fa fa-compass"></i></a></li> |
78 | 78 | <?php |
79 | - if (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d') { |
|
79 | + if (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d') { |
|
80 | 80 | if (isset($globalArchive) && $globalArchive == TRUE) { |
81 | 81 | ?> |
82 | 82 | <li><a href="#archive" role="tab" title="<?php echo _("Archive"); ?>"><i class="fa fa-archive"></i></a></li> |
83 | 83 | <?php |
84 | 84 | } |
85 | - } |
|
85 | + } |
|
86 | 86 | ?> |
87 | 87 | <li><a href="#home" role="tab" title="<?php echo _("Layers"); ?>"><i class="fa fa-map"></i></a></li> |
88 | 88 | <li><a href="#filters" role="tab" title="<?php echo _("Filters"); ?>"><i class="fa fa-filter"></i></a></li> |
89 | 89 | <li><a href="#settings" role="tab" title="<?php echo _("Settings"); ?>"><i class="fa fa-gears"></i></a></li> |
90 | 90 | <?php |
91 | - if (isset($globalMap3D) && $globalMap3D) { |
|
91 | + if (isset($globalMap3D) && $globalMap3D) { |
|
92 | 92 | if ((!isset($_COOKIE['MapFormat']) && (!isset($globalMap3Ddefault) || !$globalMap3Ddefault)) || (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] != '3d')) { |
93 | 93 | ?> |
94 | 94 | <li><a href="#" onclick="show3D(); return false;" role="tab" title="3D"><b>3D</b></a></li> |
95 | 95 | <?php |
96 | - } else { |
|
97 | - if (isset($globalMapSatellites) && $globalMapSatellites) { |
|
96 | + } else { |
|
97 | + if (isset($globalMapSatellites) && $globalMapSatellites) { |
|
98 | 98 | ?> |
99 | 99 | <li><a href="#satellites" role="tab" title="<?php echo _("Satellites"); ?>"><i class="satellite"></i></a></li> |
100 | 100 | <?php |
101 | - } |
|
101 | + } |
|
102 | 102 | ?> |
103 | 103 | <li><a href="#" onclick="show2D(); return false;" role="tab" title="2D"><b>2D</b></a></li> |
104 | 104 | <?php |
105 | 105 | } |
106 | - } |
|
106 | + } |
|
107 | 107 | ?> |
108 | 108 | </ul> |
109 | 109 | |
@@ -178,7 +178,7 @@ discard block |
||
178 | 178 | ?> |
179 | 179 | </div> |
180 | 180 | <?php |
181 | - if (isset($globalArchive) && $globalArchive == TRUE) { |
|
181 | + if (isset($globalArchive) && $globalArchive == TRUE) { |
|
182 | 182 | ?> |
183 | 183 | <div class="sidebar-pane" id="archive"> |
184 | 184 | <h1 class="sidebar-header"><?php echo _("Playback"); ?> <i>Bêta</i><span class="sidebar-close"><i class="fa fa-caret-left"></i></span></h1> |
@@ -238,7 +238,7 @@ discard block |
||
238 | 238 | </form> |
239 | 239 | </div> |
240 | 240 | <?php |
241 | - } |
|
241 | + } |
|
242 | 242 | ?> |
243 | 243 | <div class="sidebar-pane" id="settings"> |
244 | 244 | <h1 class="sidebar-header"><?php echo _("Settings"); ?><span class="sidebar-close"><i class="fa fa-caret-left"></i></span></h1> |
@@ -249,56 +249,56 @@ discard block |
||
249 | 249 | <?php |
250 | 250 | if (!isset($_COOKIE['MapType']) || $_COOKIE['MapType'] == '') $MapType = $globalMapProvider; |
251 | 251 | else $MapType = $_COOKIE['MapType']; |
252 | - ?> |
|
252 | + ?> |
|
253 | 253 | <?php |
254 | 254 | if (isset($globalBingMapKey) && $globalBingMapKey != '') { |
255 | - ?> |
|
255 | + ?> |
|
256 | 256 | <option value="Bing-Aerial"<?php if ($MapType == 'Bing-Aerial') print ' selected'; ?>>Bing-Aerial</option> |
257 | 257 | <option value="Bing-Hybrid"<?php if ($MapType == 'Bing-Hybrid') print ' selected'; ?>>Bing-Hybrid</option> |
258 | 258 | <option value="Bing-Road"<?php if ($MapType == 'Bing-Road') print ' selected'; ?>>Bing-Road</option> |
259 | 259 | <?php |
260 | 260 | } |
261 | - ?> |
|
261 | + ?> |
|
262 | 262 | <?php |
263 | - if ((!isset($_COOKIE['MapFormat']) && (!isset($globalMap3Ddefault) || !$globalMap3Ddefault)) || (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] != '3d')) { |
|
264 | - ?> |
|
263 | + if ((!isset($_COOKIE['MapFormat']) && (!isset($globalMap3Ddefault) || !$globalMap3Ddefault)) || (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] != '3d')) { |
|
264 | + ?> |
|
265 | 265 | <?php |
266 | - if (isset($globalHereappId) && $globalHereappId != '' && isset($globalHereappCode) && $globalHereappCode != '') { |
|
267 | - ?> |
|
266 | + if (isset($globalHereappId) && $globalHereappId != '' && isset($globalHereappCode) && $globalHereappCode != '') { |
|
267 | + ?> |
|
268 | 268 | <option value="Here-Aerial"<?php if ($MapType == 'Here') print ' selected'; ?>>Here-Aerial</option> |
269 | 269 | <option value="Here-Hybrid"<?php if ($MapType == 'Here') print ' selected'; ?>>Here-Hybrid</option> |
270 | 270 | <option value="Here-Road"<?php if ($MapType == 'Here') print ' selected'; ?>>Here-Road</option> |
271 | 271 | <?php |
272 | - } |
|
273 | - ?> |
|
272 | + } |
|
273 | + ?> |
|
274 | 274 | <?php |
275 | - if (isset($globalGoogleAPIKey) && $globalGoogleAPIKey != '') { |
|
276 | - ?> |
|
275 | + if (isset($globalGoogleAPIKey) && $globalGoogleAPIKey != '') { |
|
276 | + ?> |
|
277 | 277 | <option value="Google-Roadmap"<?php if ($MapType == 'Google-Roadmap') print ' selected'; ?>>Google Roadmap</option> |
278 | 278 | <option value="Google-Satellite"<?php if ($MapType == 'Google-Satellite') print ' selected'; ?>>Google Satellite</option> |
279 | 279 | <option value="Google-Hybrid"<?php if ($MapType == 'Google-Hybrid') print ' selected'; ?>>Google Hybrid</option> |
280 | 280 | <option value="Google-Terrain"<?php if ($MapType == 'Google-Terrain') print ' selected'; ?>>Google Terrain</option> |
281 | 281 | <?php |
282 | - } |
|
283 | - ?> |
|
282 | + } |
|
283 | + ?> |
|
284 | 284 | <?php |
285 | - if (isset($globalMapQuestKey) && $globalMapQuestKey != '') { |
|
286 | - ?> |
|
285 | + if (isset($globalMapQuestKey) && $globalMapQuestKey != '') { |
|
286 | + ?> |
|
287 | 287 | <option value="MapQuest-OSM"<?php if ($MapType == 'MapQuest-OSM') print ' selected'; ?>>MapQuest-OSM</option> |
288 | 288 | <option value="MapQuest-Aerial"<?php if ($MapType == 'MapQuest-Aerial') print ' selected'; ?>>MapQuest-Aerial</option> |
289 | 289 | <option value="MapQuest-Hybrid"<?php if ($MapType == 'MapQuest-Hybrid') print ' selected'; ?>>MapQuest-Hybrid</option> |
290 | 290 | <?php |
291 | - } |
|
292 | - ?> |
|
291 | + } |
|
292 | + ?> |
|
293 | 293 | <option value="Yandex"<?php if ($MapType == 'Yandex') print ' selected'; ?>>Yandex</option> |
294 | 294 | <?php |
295 | 295 | } |
296 | - ?> |
|
296 | + ?> |
|
297 | 297 | <?php |
298 | - if (isset($globalMapboxToken) && $globalMapboxToken != '') { |
|
298 | + if (isset($globalMapboxToken) && $globalMapboxToken != '') { |
|
299 | 299 | if (!isset($_COOKIE['MapTypeId'])) $MapBoxId = 'default'; |
300 | 300 | else $MapBoxId = $_COOKIE['MapTypeId']; |
301 | - ?> |
|
301 | + ?> |
|
302 | 302 | <option value="Mapbox-default"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'default') print ' selected'; ?>>Mapbox default</option> |
303 | 303 | <option value="Mapbox-mapbox.streets"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.streets') print ' selected'; ?>>Mapbox streets</option> |
304 | 304 | <option value="Mapbox-mapbox.light"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.light') print ' selected'; ?>>Mapbox light</option> |
@@ -312,13 +312,13 @@ discard block |
||
312 | 312 | <option value="Mapbox-mapbox.pirates"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.pirates') print ' selected'; ?>>Mapbox pirates</option> |
313 | 313 | <option value="Mapbox-mapbox.emerald"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.emerald') print ' selected'; ?>>Mapbox emerald</option> |
314 | 314 | <?php |
315 | - } |
|
316 | - ?> |
|
315 | + } |
|
316 | + ?> |
|
317 | 317 | <option value="OpenStreetMap"<?php if ($MapType == 'OpenStreetMap') print ' selected'; ?>>OpenStreetMap</option> |
318 | 318 | </select> |
319 | 319 | </li> |
320 | 320 | <?php |
321 | - if (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d') { |
|
321 | + if (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d') { |
|
322 | 322 | ?> |
323 | 323 | <li><?php echo _("Type of Terrain:"); ?> |
324 | 324 | <select class="selectpicker" onchange="terrainType(this);"> |
@@ -329,10 +329,10 @@ discard block |
||
329 | 329 | </select> |
330 | 330 | </li> |
331 | 331 | <?php |
332 | - } |
|
332 | + } |
|
333 | 333 | ?> |
334 | 334 | <?php |
335 | - if (!isset($_COOKIE['MapFormat']) || $_COOKIE['MapFormat'] != '3d') { |
|
335 | + if (!isset($_COOKIE['MapFormat']) || $_COOKIE['MapFormat'] != '3d') { |
|
336 | 336 | ?> |
337 | 337 | |
338 | 338 | <li><div class="checkbox"><label><input type="checkbox" name="flightpopup" value="1" onclick="clickFlightPopup(this)" <?php if (isset($_COOKIE['flightpopup']) && $_COOKIE['flightpopup'] == 'true') print 'checked'; ?> ><?php echo _("Display flight info as popup"); ?></label></div></li> |
@@ -341,89 +341,89 @@ discard block |
||
341 | 341 | <li><div class="checkbox"><label><input type="checkbox" name="flightremainingroute" value="1" onclick="clickFlightRemainingRoute(this)" <?php if ((isset($_COOKIE['MapRemainingRoute']) && $_COOKIE['MapRemainingRoute'] == 'true') || !isset($_COOKIE['MapRemainingRoute']) || (isset($globalMapRemainingRoute) && $globalMapRemainingRoute)) print 'checked'; ?> ><?php echo _("Display flight remaining route on click"); ?></label></div></li> |
342 | 342 | <li><div class="checkbox"><label><input type="checkbox" name="flightestimation" value="1" onclick="clickFlightEstimation(this)" <?php if ((isset($_COOKIE['flightestimation']) && $_COOKIE['flightestimation'] == 'true') || (!isset($_COOKIE['flightestimation']) && !isset($globalMapEstimation)) || (!isset($_COOKIE['flightestimation']) && isset($globalMapEstimation) && $globalMapEstimation)) print 'checked'; ?> ><?php echo _("Planes animate between updates"); ?></label></div></li> |
343 | 343 | <?php |
344 | - } |
|
344 | + } |
|
345 | 345 | ?> |
346 | 346 | <li><div class="checkbox"><label><input type="checkbox" name="displayairports" value="1" onclick="clickDisplayAirports(this)" <?php if (isset($_COOKIE['displayairports']) && $_COOKIE['displayairports'] == 'true' || !isset($_COOKIE['displayairports'])) print 'checked'; ?> ><?php echo _("Display airports on map"); ?></label></div></li> |
347 | 347 | <li><div class="checkbox"><label><input type="checkbox" name="displaygroundstation" value="1" onclick="clickDisplayGroundStation(this)" <?php if ((isset($_COOKIE['show_GroundStation']) && $_COOKIE['show_GroundStation'] == 'true') || (!isset($_COOKIE['show_GroundStation']) && (!isset($globalMapGroundStation) || $globalMapGroundStation === TRUE))) print 'checked'; ?> ><?php echo _("Display ground station on map"); ?></label></div></li> |
348 | 348 | <li><div class="checkbox"><label><input type="checkbox" name="displayweatherstation" value="1" onclick="clickDisplayWeatcherStation(this)" <?php if ((isset($_COOKIE['show_WeatherStation']) && $_COOKIE['show_WeatherStation'] == 'true') || (!isset($_COOKIE['show_WeatherStation']) && (!isset($globalMapWeatherStation) || $globalMapWeatherStation === TRUE))) print 'checked'; ?> ><?php echo _("Display weather station on map"); ?></label></div></li> |
349 | 349 | <li><div class="checkbox"><label><input type="checkbox" name="displaylightning" value="1" onclick="clickDisplayLightning(this)" <?php if ((isset($_COOKIE['show_Lightning']) && $_COOKIE['show_Lightning'] == 'true') || (!isset($_COOKIE['show_Lightning']) && (!isset($globalMapLightning) || $globalMapLightning === TRUE))) print 'checked'; ?> ><?php echo _("Display lightning on map"); ?></label></div></li> |
350 | 350 | <?php |
351 | - if (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d') { |
|
351 | + if (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d') { |
|
352 | 352 | ?> |
353 | 353 | <li><div class="checkbox"><label><input type="checkbox" name="displayminimap" value="1" onclick="clickDisplayMinimap(this)" <?php if (!isset($_COOKIE['displayminimap']) || (isset($_COOKIE['displayminimap']) && $_COOKIE['displayminimap'] == 'true')) print 'checked'; ?> ><?php echo _("Show mini-map"); ?></label></div></li> |
354 | 354 | <?php |
355 | - } |
|
356 | - if (time() > mktime(0,0,0,12,1,date("Y")) && time() < mktime(0,0,0,12,31,date("Y"))) { |
|
355 | + } |
|
356 | + if (time() > mktime(0,0,0,12,1,date("Y")) && time() < mktime(0,0,0,12,31,date("Y"))) { |
|
357 | 357 | ?> |
358 | 358 | <li><div class="checkbox"><label><input type="checkbox" name="displaysanta" value="1" onclick="clickSanta(this)"><i class="fa fa-snowflake-o" aria-hidden="true"></i> <?php echo _("Show Santa Claus now"); ?> <i class="fa fa-snowflake-o" aria-hidden="true"></i></label></div></li> |
359 | 359 | <?php |
360 | - } |
|
360 | + } |
|
361 | 361 | ?> |
362 | 362 | |
363 | 363 | <?php |
364 | 364 | if (function_exists('array_column')) { |
365 | - if (array_search(TRUE, array_column($globalSources, 'sourcestats')) !== FALSE) { |
|
366 | - ?> |
|
365 | + if (array_search(TRUE, array_column($globalSources, 'sourcestats')) !== FALSE) { |
|
366 | + ?> |
|
367 | 367 | <li><div class="checkbox"><label><input type="checkbox" name="flightpolar" value="1" onclick="clickPolar(this)" <?php if ((isset($_COOKIE['polar']) && $_COOKIE['polar'] == 'true')) print 'checked'; ?> ><?php echo _("Display polar on map"); ?></label></div></li> |
368 | 368 | <?php |
369 | - } |
|
369 | + } |
|
370 | 370 | } elseif (isset($globalSources)) { |
371 | - $dispolar = false; |
|
372 | - foreach ($globalSources as $testsource) { |
|
373 | - if (isset($globalSources['sourcestats']) && $globalSources['sourcestats'] !== FALSE) $dispolar = true; |
|
374 | - } |
|
375 | - if ($dispolar) { |
|
376 | - ?> |
|
371 | + $dispolar = false; |
|
372 | + foreach ($globalSources as $testsource) { |
|
373 | + if (isset($globalSources['sourcestats']) && $globalSources['sourcestats'] !== FALSE) $dispolar = true; |
|
374 | + } |
|
375 | + if ($dispolar) { |
|
376 | + ?> |
|
377 | 377 | <li><div class="checkbox"><label><input type="checkbox" name="flightpolar" value="1" onclick="clickPolar(this)" <?php if ((isset($_COOKIE['polar']) && $_COOKIE['polar'] == 'true')) print 'checked'; ?> ><?php echo _("Display polar on map"); ?></label></div></li> |
378 | 378 | <?php |
379 | - } |
|
380 | - } |
|
381 | - ?> |
|
379 | + } |
|
380 | + } |
|
381 | + ?> |
|
382 | 382 | <?php |
383 | - if (!isset($_COOKIE['MapFormat']) || $_COOKIE['MapFormat'] != '3d') { |
|
383 | + if (!isset($_COOKIE['MapFormat']) || $_COOKIE['MapFormat'] != '3d') { |
|
384 | 384 | ?> |
385 | 385 | |
386 | 386 | <?php |
387 | 387 | if (!isset($globalAircraft) || $globalAircraft === TRUE) { |
388 | - if (extension_loaded('gd') && function_exists('gd_info')) { |
|
389 | - ?> |
|
388 | + if (extension_loaded('gd') && function_exists('gd_info')) { |
|
389 | + ?> |
|
390 | 390 | <li><input type="checkbox" name="aircraftcoloraltitude" value="1" onclick="iconColorAltitude(this)" <?php if (isset($_COOKIE['IconColorAltitude']) && $_COOKIE['IconColorAltitude'] == 'true') print 'checked'; ?> ><?php echo _("Aircraft icon color based on altitude"); ?></li> |
391 | 391 | <?php |
392 | 392 | if (!isset($_COOKIE['IconColorAltitude']) || $_COOKIE['IconColorAltitude'] == 'false') { |
393 | - ?> |
|
393 | + ?> |
|
394 | 394 | <li><?php echo _("Aircraft icon color:"); ?> |
395 | 395 | <input type="color" name="aircraftcolor" id="html5colorpicker" onchange="iconColor(aircraftcolor.value);" value="#<?php if (isset($_COOKIE['IconColor'])) print $_COOKIE['IconColor']; elseif (isset($globalAircraftIconColor)) print $globalAircraftIconColor; else print '1a3151'; ?>"> |
396 | 396 | </li> |
397 | 397 | <?php |
398 | 398 | } |
399 | - } |
|
400 | - } |
|
401 | - ?> |
|
399 | + } |
|
400 | + } |
|
401 | + ?> |
|
402 | 402 | <?php |
403 | 403 | if (isset($globalMarine) && $globalMarine === TRUE) { |
404 | - if (extension_loaded('gd') && function_exists('gd_info')) { |
|
405 | - ?> |
|
404 | + if (extension_loaded('gd') && function_exists('gd_info')) { |
|
405 | + ?> |
|
406 | 406 | <li><?php echo _("Marine icon color:"); ?> |
407 | 407 | <input type="color" name="marinecolor" id="html5colorpicker" onchange="MarineiconColor(marinecolor.value);" value="#<?php if (isset($_COOKIE['MarineIconColor'])) print $_COOKIE['MarineIconColor']; elseif (isset($globalMarineIconColor)) print $globalMarineIconColor; else print '1a3151'; ?>"> |
408 | 408 | </li> |
409 | 409 | <?php |
410 | - } |
|
411 | - } |
|
412 | - ?> |
|
410 | + } |
|
411 | + } |
|
412 | + ?> |
|
413 | 413 | <?php |
414 | 414 | if (isset($globalTracker) && $globalTracker === TRUE) { |
415 | - if (extension_loaded('gd') && function_exists('gd_info')) { |
|
416 | - ?> |
|
415 | + if (extension_loaded('gd') && function_exists('gd_info')) { |
|
416 | + ?> |
|
417 | 417 | <li><?php echo _("Tracker icon color:"); ?> |
418 | 418 | <input type="color" name="trackercolor" id="html5colorpicker" onchange="TrackericonColor(trackercolor.value);" value="#<?php if (isset($_COOKIE['TrackerIconColor'])) print $_COOKIE['TrackerIconColor']; elseif (isset($globalTrackerIconColor)) print $globalTrackerIconColor; else print '1a3151'; ?>"> |
419 | 419 | </li> |
420 | 420 | <?php |
421 | - } |
|
422 | - } |
|
423 | - ?> |
|
421 | + } |
|
422 | + } |
|
423 | + ?> |
|
424 | 424 | <?php |
425 | 425 | if (!isset($globalAircraft) || $globalAircraft === TRUE) { |
426 | - ?> |
|
426 | + ?> |
|
427 | 427 | <li><?php echo _("Show airport icon at zoom level:"); ?> |
428 | 428 | <div class="range"> |
429 | 429 | <input type="range" min="0" max="19" step="1" name="airportzoom" onchange="range.value=value;airportDisplayZoom(airportzoom.value);" value="<?php if (isset($_COOKIE['AirportZoom'])) print $_COOKIE['AirportZoom']; elseif (isset($globalAirportZoom)) print $globalAirportZoom; else print '7'; ?>"> |
@@ -432,9 +432,9 @@ discard block |
||
432 | 432 | </li> |
433 | 433 | <?php |
434 | 434 | } |
435 | - ?> |
|
435 | + ?> |
|
436 | 436 | <?php |
437 | - } elseif (isset($_COOKIE['MapFormat']) || $_COOKIE['MapFOrmat'] == '3d') { |
|
437 | + } elseif (isset($_COOKIE['MapFormat']) || $_COOKIE['MapFOrmat'] == '3d') { |
|
438 | 438 | ?> |
439 | 439 | <?php |
440 | 440 | if (!isset($globalAircraft) || $globalAircraft === TRUE) { |
@@ -465,7 +465,7 @@ discard block |
||
465 | 465 | </li> |
466 | 466 | <?php |
467 | 467 | } |
468 | - } |
|
468 | + } |
|
469 | 469 | ?> |
470 | 470 | <li><?php echo _("Distance unit:"); ?> |
471 | 471 | <select class="selectpicker" onchange="unitdistance(this);"> |
@@ -498,19 +498,19 @@ discard block |
||
498 | 498 | <ul> |
499 | 499 | <?php |
500 | 500 | if (!isset($globalAircraft) || $globalAircraft) { |
501 | - ?> |
|
501 | + ?> |
|
502 | 502 | <?php |
503 | 503 | if (((isset($globalVATSIM) && $globalVATSIM) || isset($globalIVAO) && $globalIVAO || isset($globalphpVMS) && $globalphpVMS) && (!isset($globalMapVAchoose) || $globalMapVAchoose)) { |
504 | - ?> |
|
504 | + ?> |
|
505 | 505 | <?php if (isset($globalVATSIM) && $globalVATSIM) { ?><li><input type="checkbox" name="vatsim" value="1" onclick="clickVATSIM(this)" <?php if ((isset($_COOKIE['ShowVATSIM']) && $_COOKIE['ShowVATSIM'] == 'true') || !isset($_COOKIE['ShowVATSIM'])) print 'checked'; ?> ><?php echo _("Display VATSIM data"); ?></li><?php } ?> |
506 | 506 | <?php if (isset($globalIVAO) && $globalIVAO) { ?><li><input type="checkbox" name="ivao" value="1" onclick="clickIVAO(this)" <?php if ((isset($_COOKIE['ShowIVAO']) && $_COOKIE['ShowIVAO'] == 'true') || !isset($_COOKIE['ShowIVAO'])) print 'checked'; ?> ><?php echo _("Display IVAO data"); ?></li><?php } ?> |
507 | 507 | <?php if (isset($globalphpVMS) && $globalphpVMS) { ?><li><input type="checkbox" name="phpvms" value="1" onclick="clickphpVMS(this)" <?php if ((isset($_COOKIE['ShowVMS']) && $_COOKIE['ShowVMS'] == 'true') || !isset($_COOKIE['ShowVMS'])) print 'checked'; ?> ><?php echo _("Display phpVMS data"); ?></li><?php } ?> |
508 | 508 | <?php |
509 | 509 | } |
510 | - ?> |
|
510 | + ?> |
|
511 | 511 | <?php |
512 | 512 | if (!(isset($globalVA) && $globalVA) && !(isset($globalVATSIM) && $globalVATSIM) && !(isset($globalIVAO) && $globalIVAO) && !(isset($globalphpVMS) && $globalphpVMS) && isset($globalSBS1) && $globalSBS1 && isset($globalAPRS) && $globalAPRS && (!isset($globalMapchoose) || $globalMapchoose)) { |
513 | - ?> |
|
513 | + ?> |
|
514 | 514 | <?php if (isset($globalSBS1) && $globalSBS1) { ?> |
515 | 515 | <li><div class="checkbox"><label><input type="checkbox" name="sbs" value="1" onclick="clickSBS1(this)" <?php if ((isset($_COOKIE['ShowSBS1']) && $_COOKIE['ShowSBS1'] == 'true') || !isset($_COOKIE['ShowSBS1'])) print 'checked'; ?> ><?php echo _("Display ADS-B data"); ?></label></div></li> |
516 | 516 | <?php } ?> |
@@ -519,7 +519,7 @@ discard block |
||
519 | 519 | <?php } ?> |
520 | 520 | <?php |
521 | 521 | } |
522 | - ?> |
|
522 | + ?> |
|
523 | 523 | <li><?php echo _("Display airlines:"); ?> |
524 | 524 | <br/> |
525 | 525 | <select class="selectpicker" multiple onchange="airlines(this);" id="display_airlines"> |
@@ -539,14 +539,14 @@ discard block |
||
539 | 539 | echo '<option value="'.$airline['airline_icao'].'">'.$airline_name.'</option>'; |
540 | 540 | } |
541 | 541 | } |
542 | - ?> |
|
542 | + ?> |
|
543 | 543 | </select> |
544 | 544 | </li> |
545 | 545 | <?php |
546 | 546 | $Spotter = new Spotter(); |
547 | 547 | $allalliancenames = $Spotter->getAllAllianceNames(); |
548 | 548 | if (!empty($allalliancenames)) { |
549 | - ?> |
|
549 | + ?> |
|
550 | 550 | <li><?php echo _("Display alliance:"); ?> |
551 | 551 | <br/> |
552 | 552 | <select class="selectpicker" onchange="alliance(this);" id="display_alliance"> |
@@ -560,18 +560,18 @@ discard block |
||
560 | 560 | echo '<option value="'.$alliance_name.'">'.$alliance_name.'</option>'; |
561 | 561 | } |
562 | 562 | } |
563 | - ?> |
|
563 | + ?> |
|
564 | 564 | </select> |
565 | 565 | </li> |
566 | 566 | <?php |
567 | 567 | } |
568 | - ?> |
|
568 | + ?> |
|
569 | 569 | <?php |
570 | 570 | } |
571 | - ?> |
|
571 | + ?> |
|
572 | 572 | <?php |
573 | 573 | if (isset($globalAPRS) && $globalAPRS) { |
574 | - ?> |
|
574 | + ?> |
|
575 | 575 | <li><?php echo _("Display APRS sources name:"); ?> |
576 | 576 | <select class="selectpicker" multiple onchange="sources(this);"> |
577 | 577 | <?php |
@@ -583,18 +583,18 @@ discard block |
||
583 | 583 | echo '<option value="'.$source['source_name'].'">'.$source['source_name'].'</option>'; |
584 | 584 | } |
585 | 585 | } |
586 | - ?> |
|
586 | + ?> |
|
587 | 587 | </select> |
588 | 588 | </li> |
589 | 589 | <?php |
590 | 590 | } |
591 | - ?> |
|
591 | + ?> |
|
592 | 592 | <?php |
593 | 593 | if (!isset($globalAircraft) && $globalAircraft) { |
594 | - ?> |
|
594 | + ?> |
|
595 | 595 | <?php |
596 | 596 | if (!(isset($globalVATSIM) && $globalVATSIM) && !(isset($globalIVAO) && $globalIVAO) && !(isset($globalphpVMS) && $globalphpVMS)) { |
597 | - ?> |
|
597 | + ?> |
|
598 | 598 | <li><?php echo _("Display airlines of type:"); ?><br/> |
599 | 599 | <select class="selectpicker" onchange="airlinestype(this);"> |
600 | 600 | <option value="all"<?php if (!isset($_COOKIE['filter_airlinestype']) || $_COOKIE['filter_airlinestype'] == 'all' || $_COOKIE['filter_airlinestype'] == '') echo ' selected'; ?>><?php echo _("All"); ?></option> |
@@ -605,14 +605,14 @@ discard block |
||
605 | 605 | </li> |
606 | 606 | <?php |
607 | 607 | } |
608 | - ?> |
|
608 | + ?> |
|
609 | 609 | <li> |
610 | 610 | <?php echo _("Display flight with ident:"); ?> |
611 | 611 | <input type="text" name="identfilter" onchange="identfilter();" id="identfilter" value="<?php if (isset($_COOKIE['filter_ident'])) print $_COOKIE['filter_ident']; ?>" /> |
612 | 612 | </li> |
613 | 613 | <?php |
614 | 614 | } |
615 | - ?> |
|
615 | + ?> |
|
616 | 616 | </ul> |
617 | 617 | </form> |
618 | 618 | <form method="post"> |
@@ -621,7 +621,7 @@ discard block |
||
621 | 621 | </form> |
622 | 622 | </div> |
623 | 623 | <?php |
624 | - if (isset($globalMapSatellites) && $globalMapSatellites && isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d') { |
|
624 | + if (isset($globalMapSatellites) && $globalMapSatellites && isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d') { |
|
625 | 625 | ?> |
626 | 626 | <div class="sidebar-pane" id="satellites"> |
627 | 627 | <h1 class="sidebar-header"><?php echo _("Satellites"); ?><span class="sidebar-close"><i class="fa fa-caret-left"></i></span></h1> |
@@ -661,14 +661,14 @@ discard block |
||
661 | 661 | print '<option value="'.$type['tle_type'].'">'.$type_name.'</option>'; |
662 | 662 | } |
663 | 663 | } |
664 | - ?> |
|
664 | + ?> |
|
665 | 665 | </select> |
666 | 666 | </li> |
667 | 667 | </ul> |
668 | 668 | </form> |
669 | 669 | </div> |
670 | 670 | <?php |
671 | - } |
|
671 | + } |
|
672 | 672 | ?> |
673 | 673 | </div> |
674 | 674 | </div> |
@@ -157,11 +157,26 @@ discard block |
||
157 | 157 | <li><div class="checkbox"><label><input type="checkbox" name="notamcb" value="1" onclick="showNotam();" /><?php echo _("Display NOTAM"); ?></label></div></li> |
158 | 158 | <li><?php echo _("NOTAM scope:"); ?> |
159 | 159 | <select class="selectpicker" onchange="notamscope(this);"> |
160 | - <option<?php if (!isset($_COOKIE['notamscope']) || $_COOKIE['notamscope'] == 'All') print ' selected'; ?>>All</option> |
|
161 | - <option<?php if (isset($_COOKIE['notamscope']) && $_COOKIE['notamscope'] == 'Airport/Enroute warning') print ' selected'; ?>>Airport/Enroute warning</option> |
|
162 | - <option<?php if (isset($_COOKIE['notamscope']) && $_COOKIE['notamscope'] == 'Airport warning') print ' selected'; ?>>Airport warning</option> |
|
163 | - <option<?php if (isset($_COOKIE['notamscope']) && $_COOKIE['notamscope'] == 'Navigation warning') print ' selected'; ?>>Navigation warning</option> |
|
164 | - <option<?php if (isset($_COOKIE['notamscope']) && $_COOKIE['notamscope'] == 'Enroute warning') print ' selected'; ?>>Enroute warning</option> |
|
160 | + <option<?php if (!isset($_COOKIE['notamscope']) || $_COOKIE['notamscope'] == 'All') { |
|
161 | + print ' selected'; |
|
162 | +} |
|
163 | +?>>All</option> |
|
164 | + <option<?php if (isset($_COOKIE['notamscope']) && $_COOKIE['notamscope'] == 'Airport/Enroute warning') { |
|
165 | + print ' selected'; |
|
166 | +} |
|
167 | +?>>Airport/Enroute warning</option> |
|
168 | + <option<?php if (isset($_COOKIE['notamscope']) && $_COOKIE['notamscope'] == 'Airport warning') { |
|
169 | + print ' selected'; |
|
170 | +} |
|
171 | +?>>Airport warning</option> |
|
172 | + <option<?php if (isset($_COOKIE['notamscope']) && $_COOKIE['notamscope'] == 'Navigation warning') { |
|
173 | + print ' selected'; |
|
174 | +} |
|
175 | +?>>Navigation warning</option> |
|
176 | + <option<?php if (isset($_COOKIE['notamscope']) && $_COOKIE['notamscope'] == 'Enroute warning') { |
|
177 | + print ' selected'; |
|
178 | +} |
|
179 | +?>>Enroute warning</option> |
|
165 | 180 | </select |
166 | 181 | </li> |
167 | 182 | </ul> |
@@ -189,7 +204,12 @@ discard block |
||
189 | 204 | <div class="form-group"> |
190 | 205 | <label>From (UTC):</label> |
191 | 206 | <div class='input-group date' id='datetimepicker1'> |
192 | - <input type='text' name="start_date" class="form-control" value="<?php if (isset($_POST['start_date'])) print $_POST['start_date']; elseif (isset($_COOKIE['archive_begin'])) print date("m/d/Y h:i a",$_COOKIE['archive_begin']); ?>" required /> |
|
207 | + <input type='text' name="start_date" class="form-control" value="<?php if (isset($_POST['start_date'])) { |
|
208 | + print $_POST['start_date']; |
|
209 | +} elseif (isset($_COOKIE['archive_begin'])) { |
|
210 | + print date("m/d/Y h:i a",$_COOKIE['archive_begin']); |
|
211 | +} |
|
212 | +?>" required /> |
|
193 | 213 | <span class="input-group-addon"> |
194 | 214 | <span class="glyphicon glyphicon-calendar"></span> |
195 | 215 | </span> |
@@ -198,7 +218,12 @@ discard block |
||
198 | 218 | <div class="form-group"> |
199 | 219 | <label>To (UTC):</label> |
200 | 220 | <div class='input-group date' id='datetimepicker2'> |
201 | - <input type='text' name="end_date" class="form-control" value="<?php if (isset($_POST['end_date'])) print $_POST['end_date']; elseif (isset($_COOKIE['archive_end'])) print date("m/d/Y h:i a",$_COOKIE['archive_end']); ?>" /> |
|
221 | + <input type='text' name="end_date" class="form-control" value="<?php if (isset($_POST['end_date'])) { |
|
222 | + print $_POST['end_date']; |
|
223 | +} elseif (isset($_COOKIE['archive_end'])) { |
|
224 | + print date("m/d/Y h:i a",$_COOKIE['archive_end']); |
|
225 | +} |
|
226 | +?>" /> |
|
202 | 227 | <span class="input-group-addon"> |
203 | 228 | <span class="glyphicon glyphicon-calendar"></span> |
204 | 229 | </span> |
@@ -224,8 +249,20 @@ discard block |
||
224 | 249 | |
225 | 250 | <li><?php echo _("Playback speed:"); ?> |
226 | 251 | <div class="range"> |
227 | - <input type="range" min="0" max="50" step="1" name="archivespeed" onChange="archivespeedrange.value=value;" value="<?php if (isset($_POST['archivespeed'])) print $_POST['archivespeed']; elseif (isset($_COOKIE['archive_speed'])) print $_COOKIE['archive_speed']; else print '1'; ?>"> |
|
228 | - <output id="archivespeedrange"><?php if (isset($_COOKIE['archive_speed'])) print $_COOKIE['archive_speed']; else print '1'; ?></output> |
|
252 | + <input type="range" min="0" max="50" step="1" name="archivespeed" onChange="archivespeedrange.value=value;" value="<?php if (isset($_POST['archivespeed'])) { |
|
253 | + print $_POST['archivespeed']; |
|
254 | +} elseif (isset($_COOKIE['archive_speed'])) { |
|
255 | + print $_COOKIE['archive_speed']; |
|
256 | +} else { |
|
257 | + print '1'; |
|
258 | +} |
|
259 | +?>"> |
|
260 | + <output id="archivespeedrange"><?php if (isset($_COOKIE['archive_speed'])) { |
|
261 | + print $_COOKIE['archive_speed']; |
|
262 | +} else { |
|
263 | + print '1'; |
|
264 | +} |
|
265 | +?></output> |
|
229 | 266 | </div> |
230 | 267 | </li> |
231 | 268 | <li><input type="submit" name="archive" value="Show archive" class="btn btn-primary" /></li> |
@@ -247,15 +284,27 @@ discard block |
||
247 | 284 | <li><?php echo _("Type of Map:"); ?> |
248 | 285 | <select class="selectpicker" onchange="mapType(this);"> |
249 | 286 | <?php |
250 | - if (!isset($_COOKIE['MapType']) || $_COOKIE['MapType'] == '') $MapType = $globalMapProvider; |
|
251 | - else $MapType = $_COOKIE['MapType']; |
|
287 | + if (!isset($_COOKIE['MapType']) || $_COOKIE['MapType'] == '') { |
|
288 | + $MapType = $globalMapProvider; |
|
289 | + } else { |
|
290 | + $MapType = $_COOKIE['MapType']; |
|
291 | + } |
|
252 | 292 | ?> |
253 | 293 | <?php |
254 | 294 | if (isset($globalBingMapKey) && $globalBingMapKey != '') { |
255 | 295 | ?> |
256 | - <option value="Bing-Aerial"<?php if ($MapType == 'Bing-Aerial') print ' selected'; ?>>Bing-Aerial</option> |
|
257 | - <option value="Bing-Hybrid"<?php if ($MapType == 'Bing-Hybrid') print ' selected'; ?>>Bing-Hybrid</option> |
|
258 | - <option value="Bing-Road"<?php if ($MapType == 'Bing-Road') print ' selected'; ?>>Bing-Road</option> |
|
296 | + <option value="Bing-Aerial"<?php if ($MapType == 'Bing-Aerial') { |
|
297 | + print ' selected'; |
|
298 | +} |
|
299 | +?>>Bing-Aerial</option> |
|
300 | + <option value="Bing-Hybrid"<?php if ($MapType == 'Bing-Hybrid') { |
|
301 | + print ' selected'; |
|
302 | +} |
|
303 | +?>>Bing-Hybrid</option> |
|
304 | + <option value="Bing-Road"<?php if ($MapType == 'Bing-Road') { |
|
305 | + print ' selected'; |
|
306 | +} |
|
307 | +?>>Bing-Road</option> |
|
259 | 308 | <?php |
260 | 309 | } |
261 | 310 | ?> |
@@ -265,56 +314,131 @@ discard block |
||
265 | 314 | <?php |
266 | 315 | if (isset($globalHereappId) && $globalHereappId != '' && isset($globalHereappCode) && $globalHereappCode != '') { |
267 | 316 | ?> |
268 | - <option value="Here-Aerial"<?php if ($MapType == 'Here') print ' selected'; ?>>Here-Aerial</option> |
|
269 | - <option value="Here-Hybrid"<?php if ($MapType == 'Here') print ' selected'; ?>>Here-Hybrid</option> |
|
270 | - <option value="Here-Road"<?php if ($MapType == 'Here') print ' selected'; ?>>Here-Road</option> |
|
317 | + <option value="Here-Aerial"<?php if ($MapType == 'Here') { |
|
318 | + print ' selected'; |
|
319 | +} |
|
320 | +?>>Here-Aerial</option> |
|
321 | + <option value="Here-Hybrid"<?php if ($MapType == 'Here') { |
|
322 | + print ' selected'; |
|
323 | +} |
|
324 | +?>>Here-Hybrid</option> |
|
325 | + <option value="Here-Road"<?php if ($MapType == 'Here') { |
|
326 | + print ' selected'; |
|
327 | +} |
|
328 | +?>>Here-Road</option> |
|
271 | 329 | <?php |
272 | 330 | } |
273 | 331 | ?> |
274 | 332 | <?php |
275 | 333 | if (isset($globalGoogleAPIKey) && $globalGoogleAPIKey != '') { |
276 | 334 | ?> |
277 | - <option value="Google-Roadmap"<?php if ($MapType == 'Google-Roadmap') print ' selected'; ?>>Google Roadmap</option> |
|
278 | - <option value="Google-Satellite"<?php if ($MapType == 'Google-Satellite') print ' selected'; ?>>Google Satellite</option> |
|
279 | - <option value="Google-Hybrid"<?php if ($MapType == 'Google-Hybrid') print ' selected'; ?>>Google Hybrid</option> |
|
280 | - <option value="Google-Terrain"<?php if ($MapType == 'Google-Terrain') print ' selected'; ?>>Google Terrain</option> |
|
335 | + <option value="Google-Roadmap"<?php if ($MapType == 'Google-Roadmap') { |
|
336 | + print ' selected'; |
|
337 | +} |
|
338 | +?>>Google Roadmap</option> |
|
339 | + <option value="Google-Satellite"<?php if ($MapType == 'Google-Satellite') { |
|
340 | + print ' selected'; |
|
341 | +} |
|
342 | +?>>Google Satellite</option> |
|
343 | + <option value="Google-Hybrid"<?php if ($MapType == 'Google-Hybrid') { |
|
344 | + print ' selected'; |
|
345 | +} |
|
346 | +?>>Google Hybrid</option> |
|
347 | + <option value="Google-Terrain"<?php if ($MapType == 'Google-Terrain') { |
|
348 | + print ' selected'; |
|
349 | +} |
|
350 | +?>>Google Terrain</option> |
|
281 | 351 | <?php |
282 | 352 | } |
283 | 353 | ?> |
284 | 354 | <?php |
285 | 355 | if (isset($globalMapQuestKey) && $globalMapQuestKey != '') { |
286 | 356 | ?> |
287 | - <option value="MapQuest-OSM"<?php if ($MapType == 'MapQuest-OSM') print ' selected'; ?>>MapQuest-OSM</option> |
|
288 | - <option value="MapQuest-Aerial"<?php if ($MapType == 'MapQuest-Aerial') print ' selected'; ?>>MapQuest-Aerial</option> |
|
289 | - <option value="MapQuest-Hybrid"<?php if ($MapType == 'MapQuest-Hybrid') print ' selected'; ?>>MapQuest-Hybrid</option> |
|
357 | + <option value="MapQuest-OSM"<?php if ($MapType == 'MapQuest-OSM') { |
|
358 | + print ' selected'; |
|
359 | +} |
|
360 | +?>>MapQuest-OSM</option> |
|
361 | + <option value="MapQuest-Aerial"<?php if ($MapType == 'MapQuest-Aerial') { |
|
362 | + print ' selected'; |
|
363 | +} |
|
364 | +?>>MapQuest-Aerial</option> |
|
365 | + <option value="MapQuest-Hybrid"<?php if ($MapType == 'MapQuest-Hybrid') { |
|
366 | + print ' selected'; |
|
367 | +} |
|
368 | +?>>MapQuest-Hybrid</option> |
|
290 | 369 | <?php |
291 | 370 | } |
292 | 371 | ?> |
293 | - <option value="Yandex"<?php if ($MapType == 'Yandex') print ' selected'; ?>>Yandex</option> |
|
372 | + <option value="Yandex"<?php if ($MapType == 'Yandex') { |
|
373 | + print ' selected'; |
|
374 | +} |
|
375 | +?>>Yandex</option> |
|
294 | 376 | <?php |
295 | 377 | } |
296 | 378 | ?> |
297 | 379 | <?php |
298 | 380 | if (isset($globalMapboxToken) && $globalMapboxToken != '') { |
299 | - if (!isset($_COOKIE['MapTypeId'])) $MapBoxId = 'default'; |
|
300 | - else $MapBoxId = $_COOKIE['MapTypeId']; |
|
381 | + if (!isset($_COOKIE['MapTypeId'])) { |
|
382 | + $MapBoxId = 'default'; |
|
383 | + } else { |
|
384 | + $MapBoxId = $_COOKIE['MapTypeId']; |
|
385 | + } |
|
301 | 386 | ?> |
302 | - <option value="Mapbox-default"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'default') print ' selected'; ?>>Mapbox default</option> |
|
303 | - <option value="Mapbox-mapbox.streets"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.streets') print ' selected'; ?>>Mapbox streets</option> |
|
304 | - <option value="Mapbox-mapbox.light"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.light') print ' selected'; ?>>Mapbox light</option> |
|
305 | - <option value="Mapbox-mapbox.dark"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.dark') print ' selected'; ?>>Mapbox dark</option> |
|
306 | - <option value="Mapbox-mapbox.satellite"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.satellite') print ' selected'; ?>>Mapbox satellite</option> |
|
307 | - <option value="Mapbox-mapbox.streets-satellite"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.streets-satellite') print ' selected'; ?>>Mapbox streets-satellite</option> |
|
308 | - <option value="Mapbox-mapbox.streets-basic"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.streets-basic') print ' selected'; ?>>Mapbox streets-basic</option> |
|
309 | - <option value="Mapbox-mapbox.comic"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.comic') print ' selected'; ?>>Mapbox comic</option> |
|
310 | - <option value="Mapbox-mapbox.outdoors"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.outdoors') print ' selected'; ?>>Mapbox outdoors</option> |
|
311 | - <option value="Mapbox-mapbox.pencil"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.pencil') print ' selected'; ?>>Mapbox pencil</option> |
|
312 | - <option value="Mapbox-mapbox.pirates"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.pirates') print ' selected'; ?>>Mapbox pirates</option> |
|
313 | - <option value="Mapbox-mapbox.emerald"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.emerald') print ' selected'; ?>>Mapbox emerald</option> |
|
387 | + <option value="Mapbox-default"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'default') { |
|
388 | + print ' selected'; |
|
389 | +} |
|
390 | +?>>Mapbox default</option> |
|
391 | + <option value="Mapbox-mapbox.streets"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.streets') { |
|
392 | + print ' selected'; |
|
393 | +} |
|
394 | +?>>Mapbox streets</option> |
|
395 | + <option value="Mapbox-mapbox.light"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.light') { |
|
396 | + print ' selected'; |
|
397 | +} |
|
398 | +?>>Mapbox light</option> |
|
399 | + <option value="Mapbox-mapbox.dark"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.dark') { |
|
400 | + print ' selected'; |
|
401 | +} |
|
402 | +?>>Mapbox dark</option> |
|
403 | + <option value="Mapbox-mapbox.satellite"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.satellite') { |
|
404 | + print ' selected'; |
|
405 | +} |
|
406 | +?>>Mapbox satellite</option> |
|
407 | + <option value="Mapbox-mapbox.streets-satellite"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.streets-satellite') { |
|
408 | + print ' selected'; |
|
409 | +} |
|
410 | +?>>Mapbox streets-satellite</option> |
|
411 | + <option value="Mapbox-mapbox.streets-basic"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.streets-basic') { |
|
412 | + print ' selected'; |
|
413 | +} |
|
414 | +?>>Mapbox streets-basic</option> |
|
415 | + <option value="Mapbox-mapbox.comic"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.comic') { |
|
416 | + print ' selected'; |
|
417 | +} |
|
418 | +?>>Mapbox comic</option> |
|
419 | + <option value="Mapbox-mapbox.outdoors"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.outdoors') { |
|
420 | + print ' selected'; |
|
421 | +} |
|
422 | +?>>Mapbox outdoors</option> |
|
423 | + <option value="Mapbox-mapbox.pencil"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.pencil') { |
|
424 | + print ' selected'; |
|
425 | +} |
|
426 | +?>>Mapbox pencil</option> |
|
427 | + <option value="Mapbox-mapbox.pirates"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.pirates') { |
|
428 | + print ' selected'; |
|
429 | +} |
|
430 | +?>>Mapbox pirates</option> |
|
431 | + <option value="Mapbox-mapbox.emerald"<?php if ($MapType == 'Mapbox' && $MapBoxId == 'mapbox.emerald') { |
|
432 | + print ' selected'; |
|
433 | +} |
|
434 | +?>>Mapbox emerald</option> |
|
314 | 435 | <?php |
315 | 436 | } |
316 | 437 | ?> |
317 | - <option value="OpenStreetMap"<?php if ($MapType == 'OpenStreetMap') print ' selected'; ?>>OpenStreetMap</option> |
|
438 | + <option value="OpenStreetMap"<?php if ($MapType == 'OpenStreetMap') { |
|
439 | + print ' selected'; |
|
440 | +} |
|
441 | +?>>OpenStreetMap</option> |
|
318 | 442 | </select> |
319 | 443 | </li> |
320 | 444 | <?php |
@@ -322,10 +446,22 @@ discard block |
||
322 | 446 | ?> |
323 | 447 | <li><?php echo _("Type of Terrain:"); ?> |
324 | 448 | <select class="selectpicker" onchange="terrainType(this);"> |
325 | - <option value="stk"<?php if (!isset($_COOKIE['MapTerrain']) || $_COOKIE['MapTerrain'] == 'stk') print ' selected'; ?>>stk terrain</option> |
|
326 | - <option value="ellipsoid"<?php if (isset($_COOKIE['MapTerrain']) && $_COOKIE['MapTerrain'] == 'ellipsoid') print ' selected';?>>ellipsoid</option> |
|
327 | - <option value="vrterrain"<?php if (isset($_COOKIE['MapTerrain']) && $_COOKIE['MapTerrain'] == 'vrterrain') print ' selected';?>>vr terrain</option> |
|
328 | - <option value="articdem"<?php if (isset($_COOKIE['MapTerrain']) && $_COOKIE['MapTerrain'] == 'articdem') print ' selected';?>>ArticDEM</option> |
|
449 | + <option value="stk"<?php if (!isset($_COOKIE['MapTerrain']) || $_COOKIE['MapTerrain'] == 'stk') { |
|
450 | + print ' selected'; |
|
451 | +} |
|
452 | +?>>stk terrain</option> |
|
453 | + <option value="ellipsoid"<?php if (isset($_COOKIE['MapTerrain']) && $_COOKIE['MapTerrain'] == 'ellipsoid') { |
|
454 | + print ' selected'; |
|
455 | +} |
|
456 | +?>>ellipsoid</option> |
|
457 | + <option value="vrterrain"<?php if (isset($_COOKIE['MapTerrain']) && $_COOKIE['MapTerrain'] == 'vrterrain') { |
|
458 | + print ' selected'; |
|
459 | +} |
|
460 | +?>>vr terrain</option> |
|
461 | + <option value="articdem"<?php if (isset($_COOKIE['MapTerrain']) && $_COOKIE['MapTerrain'] == 'articdem') { |
|
462 | + print ' selected'; |
|
463 | +} |
|
464 | +?>>ArticDEM</option> |
|
329 | 465 | </select> |
330 | 466 | </li> |
331 | 467 | <?php |
@@ -335,22 +471,52 @@ discard block |
||
335 | 471 | if (!isset($_COOKIE['MapFormat']) || $_COOKIE['MapFormat'] != '3d') { |
336 | 472 | ?> |
337 | 473 | |
338 | - <li><div class="checkbox"><label><input type="checkbox" name="flightpopup" value="1" onclick="clickFlightPopup(this)" <?php if (isset($_COOKIE['flightpopup']) && $_COOKIE['flightpopup'] == 'true') print 'checked'; ?> ><?php echo _("Display flight info as popup"); ?></label></div></li> |
|
339 | - <li><div class="checkbox"><label><input type="checkbox" name="flightpath" value="1" onclick="clickFlightPath(this)" <?php if ((isset($_COOKIE['flightpath']) && $_COOKIE['flightpath'] == 'true')) print 'checked'; ?> ><?php echo _("Display flight path"); ?></label></div></li> |
|
340 | - <li><div class="checkbox"><label><input type="checkbox" name="flightroute" value="1" onclick="clickFlightRoute(this)" <?php if ((isset($_COOKIE['MapRoute']) && $_COOKIE['MapRoute'] == 'true') || (isset($globalMapRoute) && $globalMapRoute)) print 'checked'; ?> ><?php echo _("Display flight route on click"); ?></label></div></li> |
|
341 | - <li><div class="checkbox"><label><input type="checkbox" name="flightremainingroute" value="1" onclick="clickFlightRemainingRoute(this)" <?php if ((isset($_COOKIE['MapRemainingRoute']) && $_COOKIE['MapRemainingRoute'] == 'true') || !isset($_COOKIE['MapRemainingRoute']) || (isset($globalMapRemainingRoute) && $globalMapRemainingRoute)) print 'checked'; ?> ><?php echo _("Display flight remaining route on click"); ?></label></div></li> |
|
342 | - <li><div class="checkbox"><label><input type="checkbox" name="flightestimation" value="1" onclick="clickFlightEstimation(this)" <?php if ((isset($_COOKIE['flightestimation']) && $_COOKIE['flightestimation'] == 'true') || (!isset($_COOKIE['flightestimation']) && !isset($globalMapEstimation)) || (!isset($_COOKIE['flightestimation']) && isset($globalMapEstimation) && $globalMapEstimation)) print 'checked'; ?> ><?php echo _("Planes animate between updates"); ?></label></div></li> |
|
474 | + <li><div class="checkbox"><label><input type="checkbox" name="flightpopup" value="1" onclick="clickFlightPopup(this)" <?php if (isset($_COOKIE['flightpopup']) && $_COOKIE['flightpopup'] == 'true') { |
|
475 | + print 'checked'; |
|
476 | +} |
|
477 | +?> ><?php echo _("Display flight info as popup"); ?></label></div></li> |
|
478 | + <li><div class="checkbox"><label><input type="checkbox" name="flightpath" value="1" onclick="clickFlightPath(this)" <?php if ((isset($_COOKIE['flightpath']) && $_COOKIE['flightpath'] == 'true')) { |
|
479 | + print 'checked'; |
|
480 | +} |
|
481 | +?> ><?php echo _("Display flight path"); ?></label></div></li> |
|
482 | + <li><div class="checkbox"><label><input type="checkbox" name="flightroute" value="1" onclick="clickFlightRoute(this)" <?php if ((isset($_COOKIE['MapRoute']) && $_COOKIE['MapRoute'] == 'true') || (isset($globalMapRoute) && $globalMapRoute)) { |
|
483 | + print 'checked'; |
|
484 | +} |
|
485 | +?> ><?php echo _("Display flight route on click"); ?></label></div></li> |
|
486 | + <li><div class="checkbox"><label><input type="checkbox" name="flightremainingroute" value="1" onclick="clickFlightRemainingRoute(this)" <?php if ((isset($_COOKIE['MapRemainingRoute']) && $_COOKIE['MapRemainingRoute'] == 'true') || !isset($_COOKIE['MapRemainingRoute']) || (isset($globalMapRemainingRoute) && $globalMapRemainingRoute)) { |
|
487 | + print 'checked'; |
|
488 | +} |
|
489 | +?> ><?php echo _("Display flight remaining route on click"); ?></label></div></li> |
|
490 | + <li><div class="checkbox"><label><input type="checkbox" name="flightestimation" value="1" onclick="clickFlightEstimation(this)" <?php if ((isset($_COOKIE['flightestimation']) && $_COOKIE['flightestimation'] == 'true') || (!isset($_COOKIE['flightestimation']) && !isset($globalMapEstimation)) || (!isset($_COOKIE['flightestimation']) && isset($globalMapEstimation) && $globalMapEstimation)) { |
|
491 | + print 'checked'; |
|
492 | +} |
|
493 | +?> ><?php echo _("Planes animate between updates"); ?></label></div></li> |
|
343 | 494 | <?php |
344 | 495 | } |
345 | 496 | ?> |
346 | - <li><div class="checkbox"><label><input type="checkbox" name="displayairports" value="1" onclick="clickDisplayAirports(this)" <?php if (isset($_COOKIE['displayairports']) && $_COOKIE['displayairports'] == 'true' || !isset($_COOKIE['displayairports'])) print 'checked'; ?> ><?php echo _("Display airports on map"); ?></label></div></li> |
|
347 | - <li><div class="checkbox"><label><input type="checkbox" name="displaygroundstation" value="1" onclick="clickDisplayGroundStation(this)" <?php if ((isset($_COOKIE['show_GroundStation']) && $_COOKIE['show_GroundStation'] == 'true') || (!isset($_COOKIE['show_GroundStation']) && (!isset($globalMapGroundStation) || $globalMapGroundStation === TRUE))) print 'checked'; ?> ><?php echo _("Display ground station on map"); ?></label></div></li> |
|
348 | - <li><div class="checkbox"><label><input type="checkbox" name="displayweatherstation" value="1" onclick="clickDisplayWeatcherStation(this)" <?php if ((isset($_COOKIE['show_WeatherStation']) && $_COOKIE['show_WeatherStation'] == 'true') || (!isset($_COOKIE['show_WeatherStation']) && (!isset($globalMapWeatherStation) || $globalMapWeatherStation === TRUE))) print 'checked'; ?> ><?php echo _("Display weather station on map"); ?></label></div></li> |
|
349 | - <li><div class="checkbox"><label><input type="checkbox" name="displaylightning" value="1" onclick="clickDisplayLightning(this)" <?php if ((isset($_COOKIE['show_Lightning']) && $_COOKIE['show_Lightning'] == 'true') || (!isset($_COOKIE['show_Lightning']) && (!isset($globalMapLightning) || $globalMapLightning === TRUE))) print 'checked'; ?> ><?php echo _("Display lightning on map"); ?></label></div></li> |
|
497 | + <li><div class="checkbox"><label><input type="checkbox" name="displayairports" value="1" onclick="clickDisplayAirports(this)" <?php if (isset($_COOKIE['displayairports']) && $_COOKIE['displayairports'] == 'true' || !isset($_COOKIE['displayairports'])) { |
|
498 | + print 'checked'; |
|
499 | +} |
|
500 | +?> ><?php echo _("Display airports on map"); ?></label></div></li> |
|
501 | + <li><div class="checkbox"><label><input type="checkbox" name="displaygroundstation" value="1" onclick="clickDisplayGroundStation(this)" <?php if ((isset($_COOKIE['show_GroundStation']) && $_COOKIE['show_GroundStation'] == 'true') || (!isset($_COOKIE['show_GroundStation']) && (!isset($globalMapGroundStation) || $globalMapGroundStation === TRUE))) { |
|
502 | + print 'checked'; |
|
503 | +} |
|
504 | +?> ><?php echo _("Display ground station on map"); ?></label></div></li> |
|
505 | + <li><div class="checkbox"><label><input type="checkbox" name="displayweatherstation" value="1" onclick="clickDisplayWeatcherStation(this)" <?php if ((isset($_COOKIE['show_WeatherStation']) && $_COOKIE['show_WeatherStation'] == 'true') || (!isset($_COOKIE['show_WeatherStation']) && (!isset($globalMapWeatherStation) || $globalMapWeatherStation === TRUE))) { |
|
506 | + print 'checked'; |
|
507 | +} |
|
508 | +?> ><?php echo _("Display weather station on map"); ?></label></div></li> |
|
509 | + <li><div class="checkbox"><label><input type="checkbox" name="displaylightning" value="1" onclick="clickDisplayLightning(this)" <?php if ((isset($_COOKIE['show_Lightning']) && $_COOKIE['show_Lightning'] == 'true') || (!isset($_COOKIE['show_Lightning']) && (!isset($globalMapLightning) || $globalMapLightning === TRUE))) { |
|
510 | + print 'checked'; |
|
511 | +} |
|
512 | +?> ><?php echo _("Display lightning on map"); ?></label></div></li> |
|
350 | 513 | <?php |
351 | 514 | if (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d') { |
352 | 515 | ?> |
353 | - <li><div class="checkbox"><label><input type="checkbox" name="displayminimap" value="1" onclick="clickDisplayMinimap(this)" <?php if (!isset($_COOKIE['displayminimap']) || (isset($_COOKIE['displayminimap']) && $_COOKIE['displayminimap'] == 'true')) print 'checked'; ?> ><?php echo _("Show mini-map"); ?></label></div></li> |
|
516 | + <li><div class="checkbox"><label><input type="checkbox" name="displayminimap" value="1" onclick="clickDisplayMinimap(this)" <?php if (!isset($_COOKIE['displayminimap']) || (isset($_COOKIE['displayminimap']) && $_COOKIE['displayminimap'] == 'true')) { |
|
517 | + print 'checked'; |
|
518 | +} |
|
519 | +?> ><?php echo _("Show mini-map"); ?></label></div></li> |
|
354 | 520 | <?php |
355 | 521 | } |
356 | 522 | if (time() > mktime(0,0,0,12,1,date("Y")) && time() < mktime(0,0,0,12,31,date("Y"))) { |
@@ -364,17 +530,25 @@ discard block |
||
364 | 530 | if (function_exists('array_column')) { |
365 | 531 | if (array_search(TRUE, array_column($globalSources, 'sourcestats')) !== FALSE) { |
366 | 532 | ?> |
367 | - <li><div class="checkbox"><label><input type="checkbox" name="flightpolar" value="1" onclick="clickPolar(this)" <?php if ((isset($_COOKIE['polar']) && $_COOKIE['polar'] == 'true')) print 'checked'; ?> ><?php echo _("Display polar on map"); ?></label></div></li> |
|
533 | + <li><div class="checkbox"><label><input type="checkbox" name="flightpolar" value="1" onclick="clickPolar(this)" <?php if ((isset($_COOKIE['polar']) && $_COOKIE['polar'] == 'true')) { |
|
534 | + print 'checked'; |
|
535 | +} |
|
536 | +?> ><?php echo _("Display polar on map"); ?></label></div></li> |
|
368 | 537 | <?php |
369 | 538 | } |
370 | 539 | } elseif (isset($globalSources)) { |
371 | 540 | $dispolar = false; |
372 | 541 | foreach ($globalSources as $testsource) { |
373 | - if (isset($globalSources['sourcestats']) && $globalSources['sourcestats'] !== FALSE) $dispolar = true; |
|
542 | + if (isset($globalSources['sourcestats']) && $globalSources['sourcestats'] !== FALSE) { |
|
543 | + $dispolar = true; |
|
544 | + } |
|
374 | 545 | } |
375 | 546 | if ($dispolar) { |
376 | 547 | ?> |
377 | - <li><div class="checkbox"><label><input type="checkbox" name="flightpolar" value="1" onclick="clickPolar(this)" <?php if ((isset($_COOKIE['polar']) && $_COOKIE['polar'] == 'true')) print 'checked'; ?> ><?php echo _("Display polar on map"); ?></label></div></li> |
|
548 | + <li><div class="checkbox"><label><input type="checkbox" name="flightpolar" value="1" onclick="clickPolar(this)" <?php if ((isset($_COOKIE['polar']) && $_COOKIE['polar'] == 'true')) { |
|
549 | + print 'checked'; |
|
550 | +} |
|
551 | +?> ><?php echo _("Display polar on map"); ?></label></div></li> |
|
378 | 552 | <?php |
379 | 553 | } |
380 | 554 | } |
@@ -387,12 +561,22 @@ discard block |
||
387 | 561 | if (!isset($globalAircraft) || $globalAircraft === TRUE) { |
388 | 562 | if (extension_loaded('gd') && function_exists('gd_info')) { |
389 | 563 | ?> |
390 | - <li><input type="checkbox" name="aircraftcoloraltitude" value="1" onclick="iconColorAltitude(this)" <?php if (isset($_COOKIE['IconColorAltitude']) && $_COOKIE['IconColorAltitude'] == 'true') print 'checked'; ?> ><?php echo _("Aircraft icon color based on altitude"); ?></li> |
|
564 | + <li><input type="checkbox" name="aircraftcoloraltitude" value="1" onclick="iconColorAltitude(this)" <?php if (isset($_COOKIE['IconColorAltitude']) && $_COOKIE['IconColorAltitude'] == 'true') { |
|
565 | + print 'checked'; |
|
566 | +} |
|
567 | +?> ><?php echo _("Aircraft icon color based on altitude"); ?></li> |
|
391 | 568 | <?php |
392 | 569 | if (!isset($_COOKIE['IconColorAltitude']) || $_COOKIE['IconColorAltitude'] == 'false') { |
393 | 570 | ?> |
394 | 571 | <li><?php echo _("Aircraft icon color:"); ?> |
395 | - <input type="color" name="aircraftcolor" id="html5colorpicker" onchange="iconColor(aircraftcolor.value);" value="#<?php if (isset($_COOKIE['IconColor'])) print $_COOKIE['IconColor']; elseif (isset($globalAircraftIconColor)) print $globalAircraftIconColor; else print '1a3151'; ?>"> |
|
572 | + <input type="color" name="aircraftcolor" id="html5colorpicker" onchange="iconColor(aircraftcolor.value);" value="#<?php if (isset($_COOKIE['IconColor'])) { |
|
573 | + print $_COOKIE['IconColor']; |
|
574 | +} elseif (isset($globalAircraftIconColor)) { |
|
575 | + print $globalAircraftIconColor; |
|
576 | +} else { |
|
577 | + print '1a3151'; |
|
578 | +} |
|
579 | +?>"> |
|
396 | 580 | </li> |
397 | 581 | <?php |
398 | 582 | } |
@@ -404,7 +588,14 @@ discard block |
||
404 | 588 | if (extension_loaded('gd') && function_exists('gd_info')) { |
405 | 589 | ?> |
406 | 590 | <li><?php echo _("Marine icon color:"); ?> |
407 | - <input type="color" name="marinecolor" id="html5colorpicker" onchange="MarineiconColor(marinecolor.value);" value="#<?php if (isset($_COOKIE['MarineIconColor'])) print $_COOKIE['MarineIconColor']; elseif (isset($globalMarineIconColor)) print $globalMarineIconColor; else print '1a3151'; ?>"> |
|
591 | + <input type="color" name="marinecolor" id="html5colorpicker" onchange="MarineiconColor(marinecolor.value);" value="#<?php if (isset($_COOKIE['MarineIconColor'])) { |
|
592 | + print $_COOKIE['MarineIconColor']; |
|
593 | +} elseif (isset($globalMarineIconColor)) { |
|
594 | + print $globalMarineIconColor; |
|
595 | +} else { |
|
596 | + print '1a3151'; |
|
597 | +} |
|
598 | +?>"> |
|
408 | 599 | </li> |
409 | 600 | <?php |
410 | 601 | } |
@@ -415,7 +606,14 @@ discard block |
||
415 | 606 | if (extension_loaded('gd') && function_exists('gd_info')) { |
416 | 607 | ?> |
417 | 608 | <li><?php echo _("Tracker icon color:"); ?> |
418 | - <input type="color" name="trackercolor" id="html5colorpicker" onchange="TrackericonColor(trackercolor.value);" value="#<?php if (isset($_COOKIE['TrackerIconColor'])) print $_COOKIE['TrackerIconColor']; elseif (isset($globalTrackerIconColor)) print $globalTrackerIconColor; else print '1a3151'; ?>"> |
|
609 | + <input type="color" name="trackercolor" id="html5colorpicker" onchange="TrackericonColor(trackercolor.value);" value="#<?php if (isset($_COOKIE['TrackerIconColor'])) { |
|
610 | + print $_COOKIE['TrackerIconColor']; |
|
611 | +} elseif (isset($globalTrackerIconColor)) { |
|
612 | + print $globalTrackerIconColor; |
|
613 | +} else { |
|
614 | + print '1a3151'; |
|
615 | +} |
|
616 | +?>"> |
|
419 | 617 | </li> |
420 | 618 | <?php |
421 | 619 | } |
@@ -426,8 +624,22 @@ discard block |
||
426 | 624 | ?> |
427 | 625 | <li><?php echo _("Show airport icon at zoom level:"); ?> |
428 | 626 | <div class="range"> |
429 | - <input type="range" min="0" max="19" step="1" name="airportzoom" onchange="range.value=value;airportDisplayZoom(airportzoom.value);" value="<?php if (isset($_COOKIE['AirportZoom'])) print $_COOKIE['AirportZoom']; elseif (isset($globalAirportZoom)) print $globalAirportZoom; else print '7'; ?>"> |
|
430 | - <output id="range"><?php if (isset($_COOKIE['AirportZoom'])) print $_COOKIE['AirportZoom']; elseif (isset($globalAirportZoom)) print $globalAirportZoom; else print '7'; ?></output> |
|
627 | + <input type="range" min="0" max="19" step="1" name="airportzoom" onchange="range.value=value;airportDisplayZoom(airportzoom.value);" value="<?php if (isset($_COOKIE['AirportZoom'])) { |
|
628 | + print $_COOKIE['AirportZoom']; |
|
629 | +} elseif (isset($globalAirportZoom)) { |
|
630 | + print $globalAirportZoom; |
|
631 | +} else { |
|
632 | + print '7'; |
|
633 | +} |
|
634 | +?>"> |
|
635 | + <output id="range"><?php if (isset($_COOKIE['AirportZoom'])) { |
|
636 | + print $_COOKIE['AirportZoom']; |
|
637 | +} elseif (isset($globalAirportZoom)) { |
|
638 | + print $globalAirportZoom; |
|
639 | +} else { |
|
640 | + print '7'; |
|
641 | +} |
|
642 | +?></output> |
|
431 | 643 | </div> |
432 | 644 | </li> |
433 | 645 | <?php |
@@ -439,9 +651,19 @@ discard block |
||
439 | 651 | <?php |
440 | 652 | if (!isset($globalAircraft) || $globalAircraft === TRUE) { |
441 | 653 | ?> |
442 | - <li><input type="checkbox" name="aircraftcolorforce" value="1" onclick="iconColorForce(this)" <?php if (isset($_COOKIE['IconColorForce']) && $_COOKIE['IconColorForce'] == 'true') print 'checked'; ?> ><?php echo _("Force Aircraft color"); ?></li> |
|
654 | + <li><input type="checkbox" name="aircraftcolorforce" value="1" onclick="iconColorForce(this)" <?php if (isset($_COOKIE['IconColorForce']) && $_COOKIE['IconColorForce'] == 'true') { |
|
655 | + print 'checked'; |
|
656 | +} |
|
657 | +?> ><?php echo _("Force Aircraft color"); ?></li> |
|
443 | 658 | <li><?php echo _("Aircraft icon color:"); ?> |
444 | - <input type="color" name="aircraftcolor" id="html5colorpicker" onchange="iconColor(aircraftcolor.value);" value="#<?php if (isset($_COOKIE['IconColor'])) print $_COOKIE['IconColor']; elseif (isset($globalAircraftIconColor)) print $globalAircraftIconColor; else print 'ff0000'; ?>"> |
|
659 | + <input type="color" name="aircraftcolor" id="html5colorpicker" onchange="iconColor(aircraftcolor.value);" value="#<?php if (isset($_COOKIE['IconColor'])) { |
|
660 | + print $_COOKIE['IconColor']; |
|
661 | +} elseif (isset($globalAircraftIconColor)) { |
|
662 | + print $globalAircraftIconColor; |
|
663 | +} else { |
|
664 | + print 'ff0000'; |
|
665 | +} |
|
666 | +?>"> |
|
445 | 667 | </li> |
446 | 668 | <?php |
447 | 669 | } |
@@ -449,9 +671,19 @@ discard block |
||
449 | 671 | <?php |
450 | 672 | if (isset($globalMarine) && $globalMarine === TRUE) { |
451 | 673 | ?> |
452 | - <li><input type="checkbox" name="marinecolorforce" value="1" onclick="MarineiconColorForce(this)" <?php if (isset($_COOKIE['MarineIconColorForce']) && $_COOKIE['MarineIconColorForce'] == 'true') print 'checked'; ?> ><?php echo _("Force Marine color"); ?></li> |
|
674 | + <li><input type="checkbox" name="marinecolorforce" value="1" onclick="MarineiconColorForce(this)" <?php if (isset($_COOKIE['MarineIconColorForce']) && $_COOKIE['MarineIconColorForce'] == 'true') { |
|
675 | + print 'checked'; |
|
676 | +} |
|
677 | +?> ><?php echo _("Force Marine color"); ?></li> |
|
453 | 678 | <li><?php echo _("Marine icon color:"); ?> |
454 | - <input type="color" name="marinecolor" id="html5colorpicker" onchange="MarineiconColor(marinecolor.value);" value="#<?php if (isset($_COOKIE['MarineIconColor'])) print $_COOKIE['MarineIconColor']; elseif (isset($globalMarineIconColor)) print $globalMarineIconColor; else print 'ff0000'; ?>"> |
|
679 | + <input type="color" name="marinecolor" id="html5colorpicker" onchange="MarineiconColor(marinecolor.value);" value="#<?php if (isset($_COOKIE['MarineIconColor'])) { |
|
680 | + print $_COOKIE['MarineIconColor']; |
|
681 | +} elseif (isset($globalMarineIconColor)) { |
|
682 | + print $globalMarineIconColor; |
|
683 | +} else { |
|
684 | + print 'ff0000'; |
|
685 | +} |
|
686 | +?>"> |
|
455 | 687 | </li> |
456 | 688 | <?php |
457 | 689 | } |
@@ -459,9 +691,19 @@ discard block |
||
459 | 691 | <?php |
460 | 692 | if (isset($globalTracker) && $globalTracker === TRUE) { |
461 | 693 | ?> |
462 | - <li><input type="checkbox" name="trackercolorforce" value="1" onclick="TrackericonColorForce(this)" <?php if (isset($_COOKIE['TrackerIconColorForce']) && $_COOKIE['TrackerIconColorForce'] == 'true') print 'checked'; ?> ><?php echo _("Force Tracker color"); ?></li> |
|
694 | + <li><input type="checkbox" name="trackercolorforce" value="1" onclick="TrackericonColorForce(this)" <?php if (isset($_COOKIE['TrackerIconColorForce']) && $_COOKIE['TrackerIconColorForce'] == 'true') { |
|
695 | + print 'checked'; |
|
696 | +} |
|
697 | +?> ><?php echo _("Force Tracker color"); ?></li> |
|
463 | 698 | <li><?php echo _("Tracker icon color:"); ?> |
464 | - <input type="color" name="trackercolor" id="html5colorpicker" onchange="TrackericonColor(trackercolor.value);" value="#<?php if (isset($_COOKIE['TrackerIconColor'])) print $_COOKIE['TrackerIconColor']; elseif (isset($globalTrackerIconColor)) print $globalTrackerIconColor; else print 'ff0000'; ?>"> |
|
699 | + <input type="color" name="trackercolor" id="html5colorpicker" onchange="TrackericonColor(trackercolor.value);" value="#<?php if (isset($_COOKIE['TrackerIconColor'])) { |
|
700 | + print $_COOKIE['TrackerIconColor']; |
|
701 | +} elseif (isset($globalTrackerIconColor)) { |
|
702 | + print $globalTrackerIconColor; |
|
703 | +} else { |
|
704 | + print 'ff0000'; |
|
705 | +} |
|
706 | +?>"> |
|
465 | 707 | </li> |
466 | 708 | <?php |
467 | 709 | } |
@@ -469,22 +711,46 @@ discard block |
||
469 | 711 | ?> |
470 | 712 | <li><?php echo _("Distance unit:"); ?> |
471 | 713 | <select class="selectpicker" onchange="unitdistance(this);"> |
472 | - <option value="km"<?php if ((!isset($_COOKIE['unitdistance']) && (!isset($globalUnitDistance) || (isset($globalUnitDistance) && $globalUnitDistance == 'km'))) || (isset($_COOKIE['unitdistance']) && $_COOKIE['unitdistance'] == 'km')) echo ' selected'; ?>>km</option> |
|
473 | - <option value="nm"<?php if ((!isset($_COOKIE['unitdistance']) && isset($globalUnitDistance) && $globalUnitDistance == 'nm') || (isset($_COOKIE['unitdistance']) && $_COOKIE['unitdistance'] == 'nm')) echo ' selected'; ?>>nm</option> |
|
474 | - <option value="mi"<?php if ((!isset($_COOKIE['unitdistance']) && isset($globalUnitDistance) && $globalUnitDistance == 'mi') || (isset($_COOKIE['unitdistance']) && $_COOKIE['unitdistance'] == 'mi')) echo ' selected'; ?>>mi</option> |
|
714 | + <option value="km"<?php if ((!isset($_COOKIE['unitdistance']) && (!isset($globalUnitDistance) || (isset($globalUnitDistance) && $globalUnitDistance == 'km'))) || (isset($_COOKIE['unitdistance']) && $_COOKIE['unitdistance'] == 'km')) { |
|
715 | + echo ' selected'; |
|
716 | +} |
|
717 | +?>>km</option> |
|
718 | + <option value="nm"<?php if ((!isset($_COOKIE['unitdistance']) && isset($globalUnitDistance) && $globalUnitDistance == 'nm') || (isset($_COOKIE['unitdistance']) && $_COOKIE['unitdistance'] == 'nm')) { |
|
719 | + echo ' selected'; |
|
720 | +} |
|
721 | +?>>nm</option> |
|
722 | + <option value="mi"<?php if ((!isset($_COOKIE['unitdistance']) && isset($globalUnitDistance) && $globalUnitDistance == 'mi') || (isset($_COOKIE['unitdistance']) && $_COOKIE['unitdistance'] == 'mi')) { |
|
723 | + echo ' selected'; |
|
724 | +} |
|
725 | +?>>mi</option> |
|
475 | 726 | </select> |
476 | 727 | </li> |
477 | 728 | <li><?php echo _("Altitude unit:"); ?> |
478 | 729 | <select class="selectpicker" onchange="unitaltitude(this);"> |
479 | - <option value="m"<?php if ((!isset($_COOKIE['unitaltitude']) && (!isset($globalUnitAltitude) || (isset($globalUnitAltitude) && $globalUnitAltitude == 'm'))) || (isset($_COOKIE['unitaltitude']) && $_COOKIE['unitaltitude'] == 'm')) echo ' selected'; ?>>m</option> |
|
480 | - <option value="feet"<?php if ((!isset($_COOKIE['unitaltitude']) && isset($globalUnitAltitude) && $globalUnitAltitude == 'feet') || (isset($_COOKIE['unitaltitude']) && $_COOKIE['unitaltitude'] == 'feet')) echo ' selected'; ?>>feet</option> |
|
730 | + <option value="m"<?php if ((!isset($_COOKIE['unitaltitude']) && (!isset($globalUnitAltitude) || (isset($globalUnitAltitude) && $globalUnitAltitude == 'm'))) || (isset($_COOKIE['unitaltitude']) && $_COOKIE['unitaltitude'] == 'm')) { |
|
731 | + echo ' selected'; |
|
732 | +} |
|
733 | +?>>m</option> |
|
734 | + <option value="feet"<?php if ((!isset($_COOKIE['unitaltitude']) && isset($globalUnitAltitude) && $globalUnitAltitude == 'feet') || (isset($_COOKIE['unitaltitude']) && $_COOKIE['unitaltitude'] == 'feet')) { |
|
735 | + echo ' selected'; |
|
736 | +} |
|
737 | +?>>feet</option> |
|
481 | 738 | </select> |
482 | 739 | </li> |
483 | 740 | <li><?php echo _("Speed unit:"); ?> |
484 | 741 | <select class="selectpicker" onchange="unitspeed(this);"> |
485 | - <option value="kmh"<?php if ((!isset($_COOKIE['unitspeed']) && (!isset($globalUnitSpeed) || (isset($globalUnitSpeed) && $globalUnitSpeed == 'kmh'))) || (isset($_COOKIE['unitspeed']) && $_COOKIE['unitspeed'] == 'kmh')) echo ' selected'; ?>>km/h</option> |
|
486 | - <option value="mph"<?php if ((!isset($_COOKIE['unitspeed']) && isset($globalUnitSpeed) && $globalUnitSpeed == 'mph') || (isset($_COOKIE['unitspeed']) && $_COOKIE['unitspeed'] == 'mph')) echo ' selected'; ?>>mph</option> |
|
487 | - <option value="knots"<?php if ((!isset($_COOKIE['unitspeed']) && isset($globalUnitSpeed) && $globalUnitSpeed == 'knots') || (isset($_COOKIE['unitspeed']) && $_COOKIE['unitspeed'] == 'knots')) echo ' selected'; ?>>knots</option> |
|
742 | + <option value="kmh"<?php if ((!isset($_COOKIE['unitspeed']) && (!isset($globalUnitSpeed) || (isset($globalUnitSpeed) && $globalUnitSpeed == 'kmh'))) || (isset($_COOKIE['unitspeed']) && $_COOKIE['unitspeed'] == 'kmh')) { |
|
743 | + echo ' selected'; |
|
744 | +} |
|
745 | +?>>km/h</option> |
|
746 | + <option value="mph"<?php if ((!isset($_COOKIE['unitspeed']) && isset($globalUnitSpeed) && $globalUnitSpeed == 'mph') || (isset($_COOKIE['unitspeed']) && $_COOKIE['unitspeed'] == 'mph')) { |
|
747 | + echo ' selected'; |
|
748 | +} |
|
749 | +?>>mph</option> |
|
750 | + <option value="knots"<?php if ((!isset($_COOKIE['unitspeed']) && isset($globalUnitSpeed) && $globalUnitSpeed == 'knots') || (isset($_COOKIE['unitspeed']) && $_COOKIE['unitspeed'] == 'knots')) { |
|
751 | + echo ' selected'; |
|
752 | +} |
|
753 | +?>>knots</option> |
|
488 | 754 | </select> |
489 | 755 | </li> |
490 | 756 | |
@@ -502,9 +768,18 @@ discard block |
||
502 | 768 | <?php |
503 | 769 | if (((isset($globalVATSIM) && $globalVATSIM) || isset($globalIVAO) && $globalIVAO || isset($globalphpVMS) && $globalphpVMS) && (!isset($globalMapVAchoose) || $globalMapVAchoose)) { |
504 | 770 | ?> |
505 | - <?php if (isset($globalVATSIM) && $globalVATSIM) { ?><li><input type="checkbox" name="vatsim" value="1" onclick="clickVATSIM(this)" <?php if ((isset($_COOKIE['ShowVATSIM']) && $_COOKIE['ShowVATSIM'] == 'true') || !isset($_COOKIE['ShowVATSIM'])) print 'checked'; ?> ><?php echo _("Display VATSIM data"); ?></li><?php } ?> |
|
506 | - <?php if (isset($globalIVAO) && $globalIVAO) { ?><li><input type="checkbox" name="ivao" value="1" onclick="clickIVAO(this)" <?php if ((isset($_COOKIE['ShowIVAO']) && $_COOKIE['ShowIVAO'] == 'true') || !isset($_COOKIE['ShowIVAO'])) print 'checked'; ?> ><?php echo _("Display IVAO data"); ?></li><?php } ?> |
|
507 | - <?php if (isset($globalphpVMS) && $globalphpVMS) { ?><li><input type="checkbox" name="phpvms" value="1" onclick="clickphpVMS(this)" <?php if ((isset($_COOKIE['ShowVMS']) && $_COOKIE['ShowVMS'] == 'true') || !isset($_COOKIE['ShowVMS'])) print 'checked'; ?> ><?php echo _("Display phpVMS data"); ?></li><?php } ?> |
|
771 | + <?php if (isset($globalVATSIM) && $globalVATSIM) { ?><li><input type="checkbox" name="vatsim" value="1" onclick="clickVATSIM(this)" <?php if ((isset($_COOKIE['ShowVATSIM']) && $_COOKIE['ShowVATSIM'] == 'true') || !isset($_COOKIE['ShowVATSIM'])) { |
|
772 | + print 'checked'; |
|
773 | +} |
|
774 | +?> ><?php echo _("Display VATSIM data"); ?></li><?php } ?> |
|
775 | + <?php if (isset($globalIVAO) && $globalIVAO) { ?><li><input type="checkbox" name="ivao" value="1" onclick="clickIVAO(this)" <?php if ((isset($_COOKIE['ShowIVAO']) && $_COOKIE['ShowIVAO'] == 'true') || !isset($_COOKIE['ShowIVAO'])) { |
|
776 | + print 'checked'; |
|
777 | +} |
|
778 | +?> ><?php echo _("Display IVAO data"); ?></li><?php } ?> |
|
779 | + <?php if (isset($globalphpVMS) && $globalphpVMS) { ?><li><input type="checkbox" name="phpvms" value="1" onclick="clickphpVMS(this)" <?php if ((isset($_COOKIE['ShowVMS']) && $_COOKIE['ShowVMS'] == 'true') || !isset($_COOKIE['ShowVMS'])) { |
|
780 | + print 'checked'; |
|
781 | +} |
|
782 | +?> ><?php echo _("Display phpVMS data"); ?></li><?php } ?> |
|
508 | 783 | <?php |
509 | 784 | } |
510 | 785 | ?> |
@@ -512,10 +787,16 @@ discard block |
||
512 | 787 | if (!(isset($globalVA) && $globalVA) && !(isset($globalVATSIM) && $globalVATSIM) && !(isset($globalIVAO) && $globalIVAO) && !(isset($globalphpVMS) && $globalphpVMS) && isset($globalSBS1) && $globalSBS1 && isset($globalAPRS) && $globalAPRS && (!isset($globalMapchoose) || $globalMapchoose)) { |
513 | 788 | ?> |
514 | 789 | <?php if (isset($globalSBS1) && $globalSBS1) { ?> |
515 | - <li><div class="checkbox"><label><input type="checkbox" name="sbs" value="1" onclick="clickSBS1(this)" <?php if ((isset($_COOKIE['ShowSBS1']) && $_COOKIE['ShowSBS1'] == 'true') || !isset($_COOKIE['ShowSBS1'])) print 'checked'; ?> ><?php echo _("Display ADS-B data"); ?></label></div></li> |
|
790 | + <li><div class="checkbox"><label><input type="checkbox" name="sbs" value="1" onclick="clickSBS1(this)" <?php if ((isset($_COOKIE['ShowSBS1']) && $_COOKIE['ShowSBS1'] == 'true') || !isset($_COOKIE['ShowSBS1'])) { |
|
791 | + print 'checked'; |
|
792 | +} |
|
793 | +?> ><?php echo _("Display ADS-B data"); ?></label></div></li> |
|
516 | 794 | <?php } ?> |
517 | 795 | <?php if (isset($globalAPRS) && $globalAPRS) { ?> |
518 | - <li><div class="checkbox"><label><input type="checkbox" name="aprs" value="1" onclick="clickAPRS(this)" <?php if ((isset($_COOKIE['ShowAPRS']) && $_COOKIE['ShowAPRS'] == 'true') || !isset($_COOKIE['ShowAPRS'])) print 'checked'; ?> ><?php echo _("Display APRS data"); ?></label></div></li> |
|
796 | + <li><div class="checkbox"><label><input type="checkbox" name="aprs" value="1" onclick="clickAPRS(this)" <?php if ((isset($_COOKIE['ShowAPRS']) && $_COOKIE['ShowAPRS'] == 'true') || !isset($_COOKIE['ShowAPRS'])) { |
|
797 | + print 'checked'; |
|
798 | +} |
|
799 | +?> ><?php echo _("Display APRS data"); ?></label></div></li> |
|
519 | 800 | <?php } ?> |
520 | 801 | <?php |
521 | 802 | } |
@@ -532,7 +813,9 @@ discard block |
||
532 | 813 | } |
533 | 814 | foreach($allairlinenames as $airline) { |
534 | 815 | $airline_name = $airline['airline_name']; |
535 | - if (strlen($airline_name) > 30) $airline_name = substr($airline_name,0,30).'...'; |
|
816 | + if (strlen($airline_name) > 30) { |
|
817 | + $airline_name = substr($airline_name,0,30).'...'; |
|
818 | + } |
|
536 | 819 | if (isset($_COOKIE['filter_Airlines']) && in_array($airline['airline_icao'],explode(',',$_COOKIE['filter_Airlines']))) { |
537 | 820 | echo '<option value="'.$airline['airline_icao'].'" selected>'.$airline_name.'</option>'; |
538 | 821 | } else { |
@@ -550,7 +833,10 @@ discard block |
||
550 | 833 | <li><?php echo _("Display alliance:"); ?> |
551 | 834 | <br/> |
552 | 835 | <select class="selectpicker" onchange="alliance(this);" id="display_alliance"> |
553 | - <option value="all"<?php if (!isset($_COOKIE['filter_alliance']) || $_COOKIE['filter_alliance'] == 'all' || $_COOKIE['filter_alliance'] == '') echo ' selected'; ?>><?php echo _("All"); ?></option> |
|
836 | + <option value="all"<?php if (!isset($_COOKIE['filter_alliance']) || $_COOKIE['filter_alliance'] == 'all' || $_COOKIE['filter_alliance'] == '') { |
|
837 | + echo ' selected'; |
|
838 | +} |
|
839 | +?>><?php echo _("All"); ?></option> |
|
554 | 840 | <?php |
555 | 841 | foreach($allalliancenames as $alliance) { |
556 | 842 | $alliance_name = $alliance['alliance']; |
@@ -597,10 +883,22 @@ discard block |
||
597 | 883 | ?> |
598 | 884 | <li><?php echo _("Display airlines of type:"); ?><br/> |
599 | 885 | <select class="selectpicker" onchange="airlinestype(this);"> |
600 | - <option value="all"<?php if (!isset($_COOKIE['filter_airlinestype']) || $_COOKIE['filter_airlinestype'] == 'all' || $_COOKIE['filter_airlinestype'] == '') echo ' selected'; ?>><?php echo _("All"); ?></option> |
|
601 | - <option value="passenger"<?php if (isset($_COOKIE['filter_airlinestype']) && $_COOKIE['filter_airlinestype'] == 'passenger') echo ' selected'; ?>><?php echo _("Passenger"); ?></option> |
|
602 | - <option value="cargo"<?php if (isset($_COOKIE['filter_airlinestype']) && $_COOKIE['filter_airlinestype'] == 'cargo') echo ' selected'; ?>><?php echo _("Cargo"); ?></option> |
|
603 | - <option value="military"<?php if (isset($_COOKIE['filter_airlinestype']) && $_COOKIE['filter_airlinestype'] == 'military') echo ' selected'; ?>><?php echo _("Military"); ?></option> |
|
886 | + <option value="all"<?php if (!isset($_COOKIE['filter_airlinestype']) || $_COOKIE['filter_airlinestype'] == 'all' || $_COOKIE['filter_airlinestype'] == '') { |
|
887 | + echo ' selected'; |
|
888 | +} |
|
889 | +?>><?php echo _("All"); ?></option> |
|
890 | + <option value="passenger"<?php if (isset($_COOKIE['filter_airlinestype']) && $_COOKIE['filter_airlinestype'] == 'passenger') { |
|
891 | + echo ' selected'; |
|
892 | +} |
|
893 | +?>><?php echo _("Passenger"); ?></option> |
|
894 | + <option value="cargo"<?php if (isset($_COOKIE['filter_airlinestype']) && $_COOKIE['filter_airlinestype'] == 'cargo') { |
|
895 | + echo ' selected'; |
|
896 | +} |
|
897 | +?>><?php echo _("Cargo"); ?></option> |
|
898 | + <option value="military"<?php if (isset($_COOKIE['filter_airlinestype']) && $_COOKIE['filter_airlinestype'] == 'military') { |
|
899 | + echo ' selected'; |
|
900 | +} |
|
901 | +?>><?php echo _("Military"); ?></option> |
|
604 | 902 | </select> |
605 | 903 | </li> |
606 | 904 | <?php |
@@ -608,7 +906,10 @@ discard block |
||
608 | 906 | ?> |
609 | 907 | <li> |
610 | 908 | <?php echo _("Display flight with ident:"); ?> |
611 | - <input type="text" name="identfilter" onchange="identfilter();" id="identfilter" value="<?php if (isset($_COOKIE['filter_ident'])) print $_COOKIE['filter_ident']; ?>" /> |
|
909 | + <input type="text" name="identfilter" onchange="identfilter();" id="identfilter" value="<?php if (isset($_COOKIE['filter_ident'])) { |
|
910 | + print $_COOKIE['filter_ident']; |
|
911 | +} |
|
912 | +?>" /> |
|
612 | 913 | </li> |
613 | 914 | <?php |
614 | 915 | } |
@@ -627,7 +928,10 @@ discard block |
||
627 | 928 | <h1 class="sidebar-header"><?php echo _("Satellites"); ?><span class="sidebar-close"><i class="fa fa-caret-left"></i></span></h1> |
628 | 929 | <form> |
629 | 930 | <ul> |
630 | - <li><div class="checkbox"><label><input type="checkbox" name="displayiss" value="1" onclick="clickDisplayISS(this)" <?php if (isset($_COOKIE['displayiss']) && $_COOKIE['displayiss'] == 'true') print 'checked'; ?> ><?php echo _("Show ISS, Tiangong-1 and Tiangong-2 on map"); ?></label></div></li> |
|
931 | + <li><div class="checkbox"><label><input type="checkbox" name="displayiss" value="1" onclick="clickDisplayISS(this)" <?php if (isset($_COOKIE['displayiss']) && $_COOKIE['displayiss'] == 'true') { |
|
932 | + print 'checked'; |
|
933 | +} |
|
934 | +?> ><?php echo _("Show ISS, Tiangong-1 and Tiangong-2 on map"); ?></label></div></li> |
|
631 | 935 | <li><?php echo _("Type:"); ?> |
632 | 936 | <select class="selectpicker" multiple onchange="sattypes(this);"> |
633 | 937 | <?php |
@@ -635,25 +939,45 @@ discard block |
||
635 | 939 | $types = $Satellite->get_tle_types(); |
636 | 940 | foreach ($types as $type) { |
637 | 941 | $type_name = $type['tle_type']; |
638 | - if ($type_name == 'musson') $type_name = 'Russian LEO Navigation'; |
|
639 | - else if ($type_name == 'nnss') $type_name = 'Navi Navigation Satellite System'; |
|
640 | - else if ($type_name == 'sbas') $type_name = 'Satellite-Based Augmentation System'; |
|
641 | - else if ($type_name == 'glo-ops') $type_name = 'Glonass Operational'; |
|
642 | - else if ($type_name == 'gps-ops') $type_name = 'GPS Operational'; |
|
643 | - else if ($type_name == 'argos') $type_name = 'ARGOS Data Collection System'; |
|
644 | - else if ($type_name == 'tdrss') $type_name = 'Tracking and Data Relay Satellite System'; |
|
645 | - else if ($type_name == 'sarsat') $type_name = 'Search & Rescue'; |
|
646 | - else if ($type_name == 'dmc') $type_name = 'Disaster Monitoring'; |
|
647 | - else if ($type_name == 'resource') $type_name = 'Earth Resources'; |
|
648 | - else if ($type_name == 'stations') $type_name = 'Space Stations'; |
|
649 | - else if ($type_name == 'geo') $type_name = 'Geostationary'; |
|
650 | - else if ($type_name == 'amateur') $type_name = 'Amateur Radio'; |
|
651 | - else if ($type_name == 'x-comm') $type_name = 'Experimental'; |
|
652 | - else if ($type_name == 'other-comm') $type_name = 'Other Comm'; |
|
653 | - else if ($type_name == 'science') $type_name = 'Space & Earth Science'; |
|
654 | - else if ($type_name == 'military') $type_name = 'Miscellaneous Military'; |
|
655 | - else if ($type_name == 'radar') $type_name = 'Radar Calibration'; |
|
656 | - else if ($type_name == 'tle-new') $type_name = 'Last 30 days launches'; |
|
942 | + if ($type_name == 'musson') { |
|
943 | + $type_name = 'Russian LEO Navigation'; |
|
944 | + } else if ($type_name == 'nnss') { |
|
945 | + $type_name = 'Navi Navigation Satellite System'; |
|
946 | + } else if ($type_name == 'sbas') { |
|
947 | + $type_name = 'Satellite-Based Augmentation System'; |
|
948 | + } else if ($type_name == 'glo-ops') { |
|
949 | + $type_name = 'Glonass Operational'; |
|
950 | + } else if ($type_name == 'gps-ops') { |
|
951 | + $type_name = 'GPS Operational'; |
|
952 | + } else if ($type_name == 'argos') { |
|
953 | + $type_name = 'ARGOS Data Collection System'; |
|
954 | + } else if ($type_name == 'tdrss') { |
|
955 | + $type_name = 'Tracking and Data Relay Satellite System'; |
|
956 | + } else if ($type_name == 'sarsat') { |
|
957 | + $type_name = 'Search & Rescue'; |
|
958 | + } else if ($type_name == 'dmc') { |
|
959 | + $type_name = 'Disaster Monitoring'; |
|
960 | + } else if ($type_name == 'resource') { |
|
961 | + $type_name = 'Earth Resources'; |
|
962 | + } else if ($type_name == 'stations') { |
|
963 | + $type_name = 'Space Stations'; |
|
964 | + } else if ($type_name == 'geo') { |
|
965 | + $type_name = 'Geostationary'; |
|
966 | + } else if ($type_name == 'amateur') { |
|
967 | + $type_name = 'Amateur Radio'; |
|
968 | + } else if ($type_name == 'x-comm') { |
|
969 | + $type_name = 'Experimental'; |
|
970 | + } else if ($type_name == 'other-comm') { |
|
971 | + $type_name = 'Other Comm'; |
|
972 | + } else if ($type_name == 'science') { |
|
973 | + $type_name = 'Space & Earth Science'; |
|
974 | + } else if ($type_name == 'military') { |
|
975 | + $type_name = 'Miscellaneous Military'; |
|
976 | + } else if ($type_name == 'radar') { |
|
977 | + $type_name = 'Radar Calibration'; |
|
978 | + } else if ($type_name == 'tle-new') { |
|
979 | + $type_name = 'Last 30 days launches'; |
|
980 | + } |
|
657 | 981 | |
658 | 982 | if (isset($_COOKIE['sattypes']) && in_array($type['tle_type'],explode(',',$_COOKIE['sattypes']))) { |
659 | 983 | print '<option value="'.$type['tle_type'].'" selected>'.$type_name.'</option>'; |
@@ -385,10 +385,10 @@ discard block |
||
385 | 385 | setInterval(function(){update_locationsLayer()},<?php if (isset($globalMapRefresh)) print $globalMapRefresh*1000*2; else print '60000'; ?>); |
386 | 386 | |
387 | 387 | <?php |
388 | - // Add support for custom json via $globalMapJson |
|
389 | - if (isset($globalMapJson) && is_array($globalMapJson)) { |
|
388 | + // Add support for custom json via $globalMapJson |
|
389 | + if (isset($globalMapJson) && is_array($globalMapJson)) { |
|
390 | 390 | foreach ($globalMapJson as $json) { |
391 | - if (isset($json['url'])) { |
|
391 | + if (isset($json['url'])) { |
|
392 | 392 | ?> |
393 | 393 | update_genLayer('<?php print $json['url']; ?>'); |
394 | 394 | <?php |
@@ -397,9 +397,9 @@ discard block |
||
397 | 397 | setInterval(function(){update_genLayer('<?php print $json['url']; ?>')}, <?php print $json['refresh']; ?>); |
398 | 398 | <?php |
399 | 399 | } |
400 | - } |
|
400 | + } |
|
401 | + } |
|
401 | 402 | } |
402 | - } |
|
403 | 403 | |
404 | 404 | ?> |
405 | 405 | //adds the bootstrap tooltip to the map icons |
@@ -4,10 +4,15 @@ discard block |
||
4 | 4 | |
5 | 5 | setcookie("MapFormat",'2d'); |
6 | 6 | |
7 | -if (!isset($globalOpenWeatherMapKey)) $globalOpenWeatherMapKey = ''; |
|
7 | +if (!isset($globalOpenWeatherMapKey)) { |
|
8 | + $globalOpenWeatherMapKey = ''; |
|
9 | +} |
|
8 | 10 | // Compressed GeoJson is used if true |
9 | -if (!isset($globalJsonCompress)) $compress = true; |
|
10 | -else $compress = $globalJsonCompress; |
|
11 | +if (!isset($globalJsonCompress)) { |
|
12 | + $compress = true; |
|
13 | +} else { |
|
14 | + $compress = $globalJsonCompress; |
|
15 | +} |
|
11 | 16 | if (isset($_GET['archive'])) { |
12 | 17 | $archive = true; |
13 | 18 | //$archiveupdatetime = 50; |
@@ -18,8 +23,11 @@ discard block |
||
18 | 23 | //$lastupd = round(($_GET['enddate']-$_GET['begindate'])/(($_GET['during']*60)/10)); |
19 | 24 | //$lastupd = 20; |
20 | 25 | $lastupd = $_GET['archivespeed']*$archiveupdatetime; |
21 | - if (isset($_GET['enddate']) && $_GET['enddate'] != '') $enddate = $_GET['enddate']; |
|
22 | - else $enddate = time(); |
|
26 | + if (isset($_GET['enddate']) && $_GET['enddate'] != '') { |
|
27 | + $enddate = $_GET['enddate']; |
|
28 | + } else { |
|
29 | + $enddate = time(); |
|
30 | + } |
|
23 | 31 | setcookie("archive_begin",$begindate); |
24 | 32 | setcookie("archive_end",$enddate); |
25 | 33 | setcookie("archive_update",$lastupd); |
@@ -106,7 +114,17 @@ discard block |
||
106 | 114 | } |
107 | 115 | |
108 | 116 | //create the map |
109 | - map = L.map('archive-map', { zoomControl:false }).setView([<?php if (isset($latitude)) print $latitude; else print $globalCenterLatitude; ?>,<?php if (isset($longitude)) print $longitude; else print $globalCenterLongitude; ?>], zoom); |
|
117 | + map = L.map('archive-map', { zoomControl:false }).setView([<?php if (isset($latitude)) { |
|
118 | + print $latitude; |
|
119 | +} else { |
|
120 | + print $globalCenterLatitude; |
|
121 | +} |
|
122 | +?>,<?php if (isset($longitude)) { |
|
123 | + print $longitude; |
|
124 | +} else { |
|
125 | + print $globalCenterLongitude; |
|
126 | +} |
|
127 | +?>], zoom); |
|
110 | 128 | <?php |
111 | 129 | } else { |
112 | 130 | ?> |
@@ -119,9 +137,19 @@ discard block |
||
119 | 137 | || navigator.userAgent.match(/BlackBerry/i) |
120 | 138 | || navigator.userAgent.match(/Windows Phone/i)) |
121 | 139 | { |
122 | - var zoom = <?php if (isset($globalLiveZoom)) print $globalLiveZoom-1; else print '8'; ?>; |
|
140 | + var zoom = <?php if (isset($globalLiveZoom)) { |
|
141 | + print $globalLiveZoom-1; |
|
142 | +} else { |
|
143 | + print '8'; |
|
144 | +} |
|
145 | +?>; |
|
123 | 146 | } else { |
124 | - var zoom = <?php if (isset($globalLiveZoom)) print $globalLiveZoom; else print '9'; ?>; |
|
147 | + var zoom = <?php if (isset($globalLiveZoom)) { |
|
148 | + print $globalLiveZoom; |
|
149 | +} else { |
|
150 | + print '9'; |
|
151 | +} |
|
152 | +?>; |
|
125 | 153 | } |
126 | 154 | |
127 | 155 | //create the map |
@@ -146,16 +174,27 @@ discard block |
||
146 | 174 | bounds = L.latLngBounds(southWest,northEast); |
147 | 175 | //a few title layers |
148 | 176 | <?php |
149 | - if (isset($_COOKIE['MapType'])) $MapType = $_COOKIE['MapType']; |
|
150 | - else $MapType = $globalMapProvider; |
|
177 | + if (isset($_COOKIE['MapType'])) { |
|
178 | + $MapType = $_COOKIE['MapType']; |
|
179 | + } else { |
|
180 | + $MapType = $globalMapProvider; |
|
181 | + } |
|
151 | 182 | |
152 | 183 | if ($MapType == 'Mapbox') { |
153 | - if ($_COOKIE['MapTypeId'] == 'default') $MapBoxId = $globalMapboxId; |
|
154 | - else $MapBoxId = $_COOKIE['MapTypeId']; |
|
155 | -?> |
|
184 | + if ($_COOKIE['MapTypeId'] == 'default') { |
|
185 | + $MapBoxId = $globalMapboxId; |
|
186 | + } else { |
|
187 | + $MapBoxId = $_COOKIE['MapTypeId']; |
|
188 | + } |
|
189 | + ?> |
|
156 | 190 | L.tileLayer('https://{s}.tiles.mapbox.com/v4/{id}/{z}/{x}/{y}.png?access_token={token}', { |
157 | 191 | maxZoom: 18, |
158 | - noWrap: <?php if (isset($globalMapWrap) && !$globalMapWrap) print 'false'; else print 'true'; ?>, |
|
192 | + noWrap: <?php if (isset($globalMapWrap) && !$globalMapWrap) { |
|
193 | + print 'false'; |
|
194 | +} else { |
|
195 | + print 'true'; |
|
196 | +} |
|
197 | +?>, |
|
159 | 198 | attribution: 'Map data © <a href="http://openstreetmap.org">OpenStreetMap</a> contributors, ' + |
160 | 199 | '<a href="http://creativecommons.org/licenses/by-sa/2.0/">CC-BY-SA</a>, ' + |
161 | 200 | 'Imagery © <a href="http://mapbox.com">Mapbox</a>', |
@@ -167,7 +206,12 @@ discard block |
||
167 | 206 | ?> |
168 | 207 | L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', { |
169 | 208 | maxZoom: 18, |
170 | - noWrap: <?php if (isset($globalMapWrap) && !$globalMapWrap) print 'false'; else print 'true'; ?>, |
|
209 | + noWrap: <?php if (isset($globalMapWrap) && !$globalMapWrap) { |
|
210 | + print 'false'; |
|
211 | +} else { |
|
212 | + print 'true'; |
|
213 | +} |
|
214 | +?>, |
|
171 | 215 | attribution: 'Map data © <a href="http://openstreetmap.org">OpenStreetMap</a> contributors, ' + |
172 | 216 | '<a href="www.openstreetmap.org/copyright">Open Database Licence</a>' |
173 | 217 | }).addTo(map); |
@@ -213,20 +257,26 @@ discard block |
||
213 | 257 | map.addLayer(yandexLayer); |
214 | 258 | <?php |
215 | 259 | } elseif ($MapType == 'Bing-Aerial') { |
216 | - if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap'); |
|
217 | -?> |
|
260 | + if (!isset($globalBingMapKey) || $globalBingMapKey == '') { |
|
261 | + setcookie('MapType','OpenStreetMap'); |
|
262 | + } |
|
263 | + ?> |
|
218 | 264 | var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'Aerial'}); |
219 | 265 | map.addLayer(bingLayer); |
220 | 266 | <?php |
221 | 267 | } elseif ($MapType == 'Bing-Hybrid') { |
222 | - if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap'); |
|
223 | -?> |
|
268 | + if (!isset($globalBingMapKey) || $globalBingMapKey == '') { |
|
269 | + setcookie('MapType','OpenStreetMap'); |
|
270 | + } |
|
271 | + ?> |
|
224 | 272 | var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'AerialWithLabels'}); |
225 | 273 | map.addLayer(bingLayer); |
226 | 274 | <?php |
227 | 275 | } elseif ($MapType == 'Bing-Road') { |
228 | - if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap'); |
|
229 | -?> |
|
276 | + if (!isset($globalBingMapKey) || $globalBingMapKey == '') { |
|
277 | + setcookie('MapType','OpenStreetMap'); |
|
278 | + } |
|
279 | + ?> |
|
230 | 280 | var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'Road'}); |
231 | 281 | map.addLayer(bingLayer); |
232 | 282 | <?php |
@@ -249,9 +299,24 @@ discard block |
||
249 | 299 | $customid = $MapType; |
250 | 300 | ?> |
251 | 301 | L.tileLayer('<?php print $globalMapCustomLayer[$customid]['url']; ?>/{z}/{x}/{y}.png', { |
252 | - maxZoom: <?php if (isset($globalMapCustomLayer[$customid]['maxZoom'])) print $globalMapCustomLayer[$customid]['maxZoom']; else print '18'; ?>, |
|
253 | - minZoom: <?php if (isset($globalMapCustomLayer[$customid]['minZoom'])) print $globalMapCustomLayer[$customid]['minZoom']; else print '0'; ?>, |
|
254 | - noWrap: <?php if (isset($globalMapWrap) && !$globalMapWrap) print 'false'; else print 'true'; ?>, |
|
302 | + maxZoom: <?php if (isset($globalMapCustomLayer[$customid]['maxZoom'])) { |
|
303 | + print $globalMapCustomLayer[$customid]['maxZoom']; |
|
304 | +} else { |
|
305 | + print '18'; |
|
306 | +} |
|
307 | +?>, |
|
308 | + minZoom: <?php if (isset($globalMapCustomLayer[$customid]['minZoom'])) { |
|
309 | + print $globalMapCustomLayer[$customid]['minZoom']; |
|
310 | +} else { |
|
311 | + print '0'; |
|
312 | +} |
|
313 | +?>, |
|
314 | + noWrap: <?php if (isset($globalMapWrap) && !$globalMapWrap) { |
|
315 | + print 'false'; |
|
316 | +} else { |
|
317 | + print 'true'; |
|
318 | +} |
|
319 | +?>, |
|
255 | 320 | attribution: '<?php print $globalMapCustomLayer[$customid]['attribution']; ?>' |
256 | 321 | }).addTo(map); |
257 | 322 | |
@@ -285,7 +350,12 @@ discard block |
||
285 | 350 | } |
286 | 351 | } elseif ($globalBounding == 'circle') { |
287 | 352 | ?> |
288 | - var circle = L.circle([<?php print $globalCenterLatitude; ?>, <?php print $globalCenterLongitude; ?>],<?php if (isset($globalBoundingCircleSize)) print $globalBoundingCircleSize; else print '70000'; ?>,{ |
|
353 | + var circle = L.circle([<?php print $globalCenterLatitude; ?>, <?php print $globalCenterLongitude; ?>],<?php if (isset($globalBoundingCircleSize)) { |
|
354 | + print $globalBoundingCircleSize; |
|
355 | +} else { |
|
356 | + print '70000'; |
|
357 | +} |
|
358 | +?>,{ |
|
289 | 359 | color: '#92C7D1', |
290 | 360 | fillColor: '#92C7D1', |
291 | 361 | fillOpacity: 0.3, |
@@ -382,7 +452,12 @@ discard block |
||
382 | 452 | //} |
383 | 453 | }); |
384 | 454 | update_locationsLayer(); |
385 | -setInterval(function(){update_locationsLayer()},<?php if (isset($globalMapRefresh)) print $globalMapRefresh*1000*2; else print '60000'; ?>); |
|
455 | +setInterval(function(){update_locationsLayer()},<?php if (isset($globalMapRefresh)) { |
|
456 | + print $globalMapRefresh*1000*2; |
|
457 | +} else { |
|
458 | + print '60000'; |
|
459 | +} |
|
460 | +?>); |
|
386 | 461 | |
387 | 462 | <?php |
388 | 463 | // Add support for custom json via $globalMapJson |