@@ -12,16 +12,27 @@ discard block |
||
| 12 | 12 | <?php |
| 13 | 13 | |
| 14 | 14 | // Compressed GeoJson is used if true |
| 15 | -if (!isset($globalJsonCompress)) $compress = true; |
|
| 16 | -else $compress = $globalJsonCompress; |
|
| 15 | +if (!isset($globalJsonCompress)) { |
|
| 16 | + $compress = true; |
|
| 17 | +} else { |
|
| 18 | + $compress = $globalJsonCompress; |
|
| 19 | +} |
|
| 17 | 20 | |
| 18 | -if (isset($_GET['ident'])) $ident = filter_input(INPUT_GET,'ident',FILTER_SANITIZE_STRING); |
|
| 19 | -if (isset($_GET['flightaware_id'])) $flightaware_id = filter_input(INPUT_GET,'flightaware_id',FILTER_SANITIZE_STRING); |
|
| 21 | +if (isset($_GET['ident'])) { |
|
| 22 | + $ident = filter_input(INPUT_GET,'ident',FILTER_SANITIZE_STRING); |
|
| 23 | +} |
|
| 24 | +if (isset($_GET['flightaware_id'])) { |
|
| 25 | + $flightaware_id = filter_input(INPUT_GET,'flightaware_id',FILTER_SANITIZE_STRING); |
|
| 26 | +} |
|
| 20 | 27 | ?> |
| 21 | 28 | <?php |
| 22 | -if (isset($_COOKIE['IconColor'])) $IconColor = $_COOKIE['IconColor']; |
|
| 23 | -elseif (isset($globalAircraftIconColor)) $IconColor = $globalAircraftIconColor; |
|
| 24 | -else $IconColor = '1a3151'; |
|
| 29 | +if (isset($_COOKIE['IconColor'])) { |
|
| 30 | + $IconColor = $_COOKIE['IconColor']; |
|
| 31 | +} elseif (isset($globalAircraftIconColor)) { |
|
| 32 | + $IconColor = $globalAircraftIconColor; |
|
| 33 | +} else { |
|
| 34 | + $IconColor = '1a3151'; |
|
| 35 | +} |
|
| 25 | 36 | ?> |
| 26 | 37 | <?php |
| 27 | 38 | if (isset($globalDebug) && $globalDebug === TRUE) { |
@@ -99,9 +110,12 @@ discard block |
||
| 99 | 110 | |
| 100 | 111 | function update_airportsLayer() { |
| 101 | 112 | <?php |
| 102 | - if (isset($_COOKIE['AirportZoom'])) $getZoom = $_COOKIE['AirportZoom']; |
|
| 103 | - else $getZoom = '7'; |
|
| 104 | -?> |
|
| 113 | + if (isset($_COOKIE['AirportZoom'])) { |
|
| 114 | + $getZoom = $_COOKIE['AirportZoom']; |
|
| 115 | + } else { |
|
| 116 | + $getZoom = '7'; |
|
| 117 | + } |
|
| 118 | + ?> |
|
| 105 | 119 | if (typeof airportsLayer != 'undefined') { |
| 106 | 120 | if (map.hasLayer(airportsLayer) == true) { |
| 107 | 121 | map.removeLayer(airportsLayer); |
@@ -382,7 +396,12 @@ discard block |
||
| 382 | 396 | <?php |
| 383 | 397 | } else { |
| 384 | 398 | ?> |
| 385 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 399 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) { |
|
| 400 | + print $archiveupdatetime*1000; |
|
| 401 | +} else { |
|
| 402 | + print $globalMapRefresh*1000+20000; |
|
| 403 | +} |
|
| 404 | +?>+feature.properties.sqt*1000); |
|
| 386 | 405 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 387 | 406 | <?php |
| 388 | 407 | } |
@@ -433,7 +452,12 @@ discard block |
||
| 433 | 452 | <?php |
| 434 | 453 | } else { |
| 435 | 454 | ?> |
| 436 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 455 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) { |
|
| 456 | + print $archiveupdatetime*1000; |
|
| 457 | +} else { |
|
| 458 | + print $globalMapRefresh*1000+20000; |
|
| 459 | +} |
|
| 460 | +?>+feature.properties.sqt*1000); |
|
| 437 | 461 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 438 | 462 | <?php |
| 439 | 463 | } |
@@ -481,7 +505,12 @@ discard block |
||
| 481 | 505 | <?php |
| 482 | 506 | } else { |
| 483 | 507 | ?> |
| 484 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 508 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) { |
|
| 509 | + print $archiveupdatetime*1000; |
|
| 510 | +} else { |
|
| 511 | + print $globalMapRefresh*1000+20000; |
|
| 512 | +} |
|
| 513 | +?>+feature.properties.sqt*1000); |
|
| 485 | 514 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 486 | 515 | <?php |
| 487 | 516 | } |
@@ -1000,7 +1029,12 @@ discard block |
||
| 1000 | 1029 | update_archiveLayer(0); |
| 1001 | 1030 | } else { |
| 1002 | 1031 | //then load it again every 30 seconds |
| 1003 | - reloadPage = setInterval(function(){if (noTimeout) getLiveData(0)},<?php if (isset($globalMapRefresh)) print $globalMapRefresh*1000; else print '30000'; ?>); |
|
| 1032 | + reloadPage = setInterval(function(){if (noTimeout) getLiveData(0)},<?php if (isset($globalMapRefresh)) { |
|
| 1033 | + print $globalMapRefresh*1000; |
|
| 1034 | +} else { |
|
| 1035 | + print '30000'; |
|
| 1036 | +} |
|
| 1037 | +?>); |
|
| 1004 | 1038 | var currentdate = new Date(); |
| 1005 | 1039 | var currentyear = new Date().getFullYear(); |
| 1006 | 1040 | var begindate = new Date(Date.UTC(currentyear,11,24,2,0,0,0)); |
@@ -1012,7 +1046,12 @@ discard block |
||
| 1012 | 1046 | if (!((isset($globalIVAO) && $globalIVAO) || (isset($globalVATSIM) && $globalVATSIM) || (isset($globalphpVMS) && $globalphpVMS)) && (isset($_COOKIE['polar']) && $_COOKIE['polar'] == 'true')) { |
| 1013 | 1047 | ?> |
| 1014 | 1048 | update_polarLayer(); |
| 1015 | - setInterval(function(){map.removeLayer(polarLayer);update_polarLayer()},<?php if (isset($globalMapRefresh)) print $globalMapRefresh*1000*2; else print '60000'; ?>); |
|
| 1049 | + setInterval(function(){map.removeLayer(polarLayer);update_polarLayer()},<?php if (isset($globalMapRefresh)) { |
|
| 1050 | + print $globalMapRefresh*1000*2; |
|
| 1051 | +} else { |
|
| 1052 | + print '60000'; |
|
| 1053 | +} |
|
| 1054 | +?>); |
|
| 1016 | 1055 | <?php |
| 1017 | 1056 | } |
| 1018 | 1057 | ?> |
@@ -1025,7 +1064,12 @@ discard block |
||
| 1025 | 1064 | if ((isset($globalIVAO) && $globalIVAO) || (isset($globalVATSIM) && $globalVATSIM)) { |
| 1026 | 1065 | ?> |
| 1027 | 1066 | update_atcLayer(); |
| 1028 | - setInterval(function(){map.removeLayer(atcLayer);update_atcLayer()},<?php if (isset($globalMapRefresh)) print $globalMapRefresh*1000*2; else print '60000'; ?>); |
|
| 1067 | + setInterval(function(){map.removeLayer(atcLayer);update_atcLayer()},<?php if (isset($globalMapRefresh)) { |
|
| 1068 | + print $globalMapRefresh*1000*2; |
|
| 1069 | +} else { |
|
| 1070 | + print '60000'; |
|
| 1071 | +} |
|
| 1072 | +?>); |
|
| 1029 | 1073 | <?php |
| 1030 | 1074 | } |
| 1031 | 1075 | ?> |
@@ -10,7 +10,7 @@ discard block |
||
| 10 | 10 | * For more information see: https://www.flightairmap.com/ |
| 11 | 11 | */ |
| 12 | 12 | <?php |
| 13 | -setcookie("MapFormat",'2d'); |
|
| 13 | +setcookie("MapFormat", '2d'); |
|
| 14 | 14 | |
| 15 | 15 | // Compressed GeoJson is used if true |
| 16 | 16 | if (!isset($globalJsonCompress)) $compress = true; |
@@ -26,10 +26,10 @@ discard block |
||
| 26 | 26 | |
| 27 | 27 | <?php |
| 28 | 28 | if (isset($_GET['famsatid'])) { |
| 29 | - $famsatid = filter_input(INPUT_GET,'famsatid',FILTER_SANITIZE_STRING); |
|
| 29 | + $famsatid = filter_input(INPUT_GET, 'famsatid', FILTER_SANITIZE_STRING); |
|
| 30 | 30 | } |
| 31 | 31 | if (isset($_GET['ident'])) { |
| 32 | - $ident = filter_input(INPUT_GET,'ident',FILTER_SANITIZE_STRING); |
|
| 32 | + $ident = filter_input(INPUT_GET, 'ident', FILTER_SANITIZE_STRING); |
|
| 33 | 33 | } |
| 34 | 34 | if (!isset($ident) && !isset($famsatid)) { |
| 35 | 35 | ?> |
@@ -174,7 +174,7 @@ discard block |
||
| 174 | 174 | <?php |
| 175 | 175 | } else { |
| 176 | 176 | ?> |
| 177 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 177 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000); |
|
| 178 | 178 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 179 | 179 | <?php |
| 180 | 180 | } |
@@ -190,7 +190,7 @@ discard block |
||
| 190 | 190 | /* |
| 191 | 191 | shadowUrl: iconURLShadowpath, |
| 192 | 192 | shadowSize: [<?php print $globalAircraftSize; ?>, <?php print $globalAircraftSize; ?>], |
| 193 | - shadowAnchor: [<?php print ($globalAircraftSize/2)+1; ?>, <?php print $globalAircraftSize; ?>] |
|
| 193 | + shadowAnchor: [<?php print ($globalAircraftSize/2) + 1; ?>, <?php print $globalAircraftSize; ?>] |
|
| 194 | 194 | */ |
| 195 | 195 | }) |
| 196 | 196 | }) |
@@ -231,7 +231,7 @@ discard block |
||
| 231 | 231 | <?php |
| 232 | 232 | } else { |
| 233 | 233 | ?> |
| 234 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 234 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000); |
|
| 235 | 235 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 236 | 236 | <?php |
| 237 | 237 | } |
@@ -287,7 +287,7 @@ discard block |
||
| 287 | 287 | <?php |
| 288 | 288 | } else { |
| 289 | 289 | ?> |
| 290 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 290 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000); |
|
| 291 | 291 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 292 | 292 | <?php |
| 293 | 293 | } |
@@ -10,7 +10,7 @@ discard block |
||
| 10 | 10 | * For more information see: https://www.flightairmap.com/ |
| 11 | 11 | */ |
| 12 | 12 | <?php |
| 13 | -setcookie("MapFormat",'2d'); |
|
| 13 | +setcookie("MapFormat", '2d'); |
|
| 14 | 14 | |
| 15 | 15 | // Compressed GeoJson is used if true |
| 16 | 16 | if (!isset($globalJsonCompress)) $compress = true; |
@@ -27,10 +27,10 @@ discard block |
||
| 27 | 27 | |
| 28 | 28 | <?php |
| 29 | 29 | if (isset($_GET['famtrackid'])) { |
| 30 | - $famtrackid = filter_input(INPUT_GET,'famtrackid',FILTER_SANITIZE_STRING); |
|
| 30 | + $famtrackid = filter_input(INPUT_GET, 'famtrackid', FILTER_SANITIZE_STRING); |
|
| 31 | 31 | } |
| 32 | 32 | if (isset($_GET['ident'])) { |
| 33 | - $ident = filter_input(INPUT_GET,'ident',FILTER_SANITIZE_STRING); |
|
| 33 | + $ident = filter_input(INPUT_GET, 'ident', FILTER_SANITIZE_STRING); |
|
| 34 | 34 | } |
| 35 | 35 | if (!isset($ident) && !isset($famtrackid)) { |
| 36 | 36 | ?> |
@@ -210,7 +210,7 @@ discard block |
||
| 210 | 210 | <?php |
| 211 | 211 | } else { |
| 212 | 212 | ?> |
| 213 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 213 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000); |
|
| 214 | 214 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 215 | 215 | <?php |
| 216 | 216 | } |
@@ -226,7 +226,7 @@ discard block |
||
| 226 | 226 | /* |
| 227 | 227 | shadowUrl: iconURLShadowpath, |
| 228 | 228 | shadowSize: [<?php print $globalAircraftSize; ?>, <?php print $globalAircraftSize; ?>], |
| 229 | - shadowAnchor: [<?php print ($globalAircraftSize/2)+1; ?>, <?php print $globalAircraftSize; ?>] |
|
| 229 | + shadowAnchor: [<?php print ($globalAircraftSize/2) + 1; ?>, <?php print $globalAircraftSize; ?>] |
|
| 230 | 230 | */ |
| 231 | 231 | }) |
| 232 | 232 | }) |
@@ -267,7 +267,7 @@ discard block |
||
| 267 | 267 | <?php |
| 268 | 268 | } else { |
| 269 | 269 | ?> |
| 270 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 270 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000); |
|
| 271 | 271 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 272 | 272 | <?php |
| 273 | 273 | } |
@@ -323,7 +323,7 @@ discard block |
||
| 323 | 323 | <?php |
| 324 | 324 | } else { |
| 325 | 325 | ?> |
| 326 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 326 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000); |
|
| 327 | 327 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 328 | 328 | <?php |
| 329 | 329 | } |
@@ -10,7 +10,7 @@ discard block |
||
| 10 | 10 | * For more information see: https://www.flightairmap.com/ |
| 11 | 11 | */ |
| 12 | 12 | <?php |
| 13 | -setcookie("MapFormat",'2d'); |
|
| 13 | +setcookie("MapFormat", '2d'); |
|
| 14 | 14 | |
| 15 | 15 | // Compressed GeoJson is used if true |
| 16 | 16 | if (!isset($globalJsonCompress)) $compress = true; |
@@ -37,10 +37,10 @@ discard block |
||
| 37 | 37 | |
| 38 | 38 | <?php |
| 39 | 39 | if (isset($_GET['fammarine_id'])) { |
| 40 | - $fammarine_id = filter_input(INPUT_GET,'fammarine_id',FILTER_SANITIZE_STRING); |
|
| 40 | + $fammarine_id = filter_input(INPUT_GET, 'fammarine_id', FILTER_SANITIZE_STRING); |
|
| 41 | 41 | } |
| 42 | 42 | if (isset($_GET['ident'])) { |
| 43 | - $ident = filter_input(INPUT_GET,'ident',FILTER_SANITIZE_STRING); |
|
| 43 | + $ident = filter_input(INPUT_GET, 'ident', FILTER_SANITIZE_STRING); |
|
| 44 | 44 | } |
| 45 | 45 | if (!isset($ident) && !isset($fammarine_id)) { |
| 46 | 46 | ?> |
@@ -200,7 +200,7 @@ discard block |
||
| 200 | 200 | <?php |
| 201 | 201 | } else { |
| 202 | 202 | ?> |
| 203 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 203 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000); |
|
| 204 | 204 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 205 | 205 | <?php |
| 206 | 206 | } |
@@ -216,7 +216,7 @@ discard block |
||
| 216 | 216 | /* |
| 217 | 217 | shadowUrl: iconURLShadowpath, |
| 218 | 218 | shadowSize: [<?php print $globalAircraftSize; ?>, <?php print $globalAircraftSize; ?>], |
| 219 | - shadowAnchor: [<?php print ($globalAircraftSize/2)+1; ?>, <?php print $globalAircraftSize; ?>] |
|
| 219 | + shadowAnchor: [<?php print ($globalAircraftSize/2) + 1; ?>, <?php print $globalAircraftSize; ?>] |
|
| 220 | 220 | */ |
| 221 | 221 | }) |
| 222 | 222 | }) |
@@ -257,7 +257,7 @@ discard block |
||
| 257 | 257 | <?php |
| 258 | 258 | } else { |
| 259 | 259 | ?> |
| 260 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 260 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000); |
|
| 261 | 261 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 262 | 262 | <?php |
| 263 | 263 | } |
@@ -313,7 +313,7 @@ discard block |
||
| 313 | 313 | <?php |
| 314 | 314 | } else { |
| 315 | 315 | ?> |
| 316 | - var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000); |
|
| 316 | + var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000); |
|
| 317 | 317 | return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{ |
| 318 | 318 | <?php |
| 319 | 319 | } |
@@ -11,7 +11,7 @@ discard block |
||
| 11 | 11 | */ |
| 12 | 12 | <?php |
| 13 | 13 | |
| 14 | -setcookie("MapFormat",'2d'); |
|
| 14 | +setcookie("MapFormat", '2d'); |
|
| 15 | 15 | |
| 16 | 16 | if (!isset($globalOpenWeatherMapKey)) $globalOpenWeatherMapKey = ''; |
| 17 | 17 | // Compressed GeoJson is used if true |
@@ -109,16 +109,16 @@ discard block |
||
| 109 | 109 | <?php |
| 110 | 110 | } |
| 111 | 111 | if (isset($_GET['ident'])) { |
| 112 | - $ident = filter_input(INPUT_GET,'ident',FILTER_SANITIZE_STRING); |
|
| 112 | + $ident = filter_input(INPUT_GET, 'ident', FILTER_SANITIZE_STRING); |
|
| 113 | 113 | } |
| 114 | 114 | if (isset($_GET['flightaware_id'])) { |
| 115 | - $flightaware_id = filter_input(INPUT_GET,'flightaware_id',FILTER_SANITIZE_STRING); |
|
| 115 | + $flightaware_id = filter_input(INPUT_GET, 'flightaware_id', FILTER_SANITIZE_STRING); |
|
| 116 | 116 | } |
| 117 | 117 | if (isset($_GET['latitude'])) { |
| 118 | - $latitude = filter_input(INPUT_GET,'latitude',FILTER_SANITIZE_STRING); |
|
| 118 | + $latitude = filter_input(INPUT_GET, 'latitude', FILTER_SANITIZE_STRING); |
|
| 119 | 119 | } |
| 120 | 120 | if (isset($_GET['longitude'])) { |
| 121 | - $longitude = filter_input(INPUT_GET,'longitude',FILTER_SANITIZE_STRING); |
|
| 121 | + $longitude = filter_input(INPUT_GET, 'longitude', FILTER_SANITIZE_STRING); |
|
| 122 | 122 | } |
| 123 | 123 | ?> |
| 124 | 124 | |
@@ -146,7 +146,7 @@ discard block |
||
| 146 | 146 | } else { |
| 147 | 147 | if ((isset($globalCenterLatitude) && $globalCenterLatitude != '' && isset($globalCenterLongitude) && $globalCenterLongitude != '') || isset($_COOKIE['lastcentercoord'])) { |
| 148 | 148 | if (isset($_COOKIE['lastcentercoord'])) { |
| 149 | - $lastcentercoord = explode(',',$_COOKIE['lastcentercoord']); |
|
| 149 | + $lastcentercoord = explode(',', $_COOKIE['lastcentercoord']); |
|
| 150 | 150 | $viewcenterlatitude = $lastcentercoord[0]; |
| 151 | 151 | $viewcenterlongitude = $lastcentercoord[1]; |
| 152 | 152 | $viewzoom = $lastcentercoord[2]; |
@@ -167,7 +167,7 @@ discard block |
||
| 167 | 167 | || navigator.userAgent.match(/BlackBerry/i) |
| 168 | 168 | || navigator.userAgent.match(/Windows Phone/i)) |
| 169 | 169 | { |
| 170 | - var zoom = <?php if (isset($viewzoom) && $viewzoom == $globalLiveZoom) print $viewzoom-1; elseif (isset($viewzoom)) print $viewzoom; else print '8'; ?>; |
|
| 170 | + var zoom = <?php if (isset($viewzoom) && $viewzoom == $globalLiveZoom) print $viewzoom - 1; elseif (isset($viewzoom)) print $viewzoom; else print '8'; ?>; |
|
| 171 | 171 | } else { |
| 172 | 172 | var zoom = <?php if (isset($viewzoom)) print $viewzoom; else print '9'; ?>; |
| 173 | 173 | } |
@@ -311,19 +311,19 @@ discard block |
||
| 311 | 311 | map.addLayer(yandexLayer); |
| 312 | 312 | <?php |
| 313 | 313 | } elseif ($MapType == 'Bing-Aerial') { |
| 314 | - if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap'); |
|
| 314 | + if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType', 'OpenStreetMap'); |
|
| 315 | 315 | ?> |
| 316 | 316 | var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'Aerial'}); |
| 317 | 317 | map.addLayer(bingLayer); |
| 318 | 318 | <?php |
| 319 | 319 | } elseif ($MapType == 'Bing-Hybrid') { |
| 320 | - if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap'); |
|
| 320 | + if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType', 'OpenStreetMap'); |
|
| 321 | 321 | ?> |
| 322 | 322 | var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'AerialWithLabels'}); |
| 323 | 323 | map.addLayer(bingLayer); |
| 324 | 324 | <?php |
| 325 | 325 | } elseif ($MapType == 'Bing-Road') { |
| 326 | - if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap'); |
|
| 326 | + if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType', 'OpenStreetMap'); |
|
| 327 | 327 | ?> |
| 328 | 328 | var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'Road'}); |
| 329 | 329 | map.addLayer(bingLayer); |
@@ -461,7 +461,7 @@ discard block |
||
| 461 | 461 | |
| 462 | 462 | function update_tsk() { |
| 463 | 463 | var bbox = map.getBounds().toBBoxString(); |
| 464 | - var tskLayerQuery = $.getJSON("<?php print $globalURL; ?>/tsk-geojson.php?tsk=<?php echo filter_input(INPUT_GET,'tsk',FILTER_SANITIZE_URL); ?>",function (data) { |
|
| 464 | + var tskLayerQuery = $.getJSON("<?php print $globalURL; ?>/tsk-geojson.php?tsk=<?php echo filter_input(INPUT_GET, 'tsk', FILTER_SANITIZE_URL); ?>",function (data) { |
|
| 465 | 465 | tskLayer = L.geoJson(data,{ |
| 466 | 466 | onEachFeature: function (feature, layer) { |
| 467 | 467 | tskPopup(feature, layer); |