Ysurac /
FlightAirMap
These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more
| 1 | <?php |
||
| 2 | if (isset($globalProtect) && $globalProtect) { |
||
| 3 | @session_start(); |
||
|
0 ignored issues
–
show
|
|||
| 4 | $_SESSION['protect'] = 'protect'; |
||
| 5 | } |
||
| 6 | //gets the page file and stores it in a variable |
||
| 7 | $file_path = pathinfo($_SERVER['SCRIPT_NAME']); |
||
| 8 | $current_page = $file_path['filename']; |
||
| 9 | if ($globalTimezone == '') $globalTimezone = 'UTC'; |
||
| 10 | date_default_timezone_set($globalTimezone); |
||
| 11 | if (isset($_COOKIE['MapType']) && $_COOKIE['MapType'] != '') $MapType = $_COOKIE['MapType']; |
||
| 12 | else $MapType = $globalMapProvider; |
||
| 13 | |||
| 14 | if (isset($globalMapOffline) && $globalMapOffline) $MapType = 'offline'; |
||
| 15 | |||
| 16 | if (isset($_GET['3d'])) { |
||
| 17 | setcookie('MapFormat','3d'); |
||
| 18 | } else if (isset($_GET['2d'])) { |
||
| 19 | setcookie('MapFormat','2d'); |
||
| 20 | } |
||
| 21 | |||
| 22 | if (isset($globalTSK) && $globalTSK && isset($_GET['tsk'])) { |
||
| 23 | $tsk = filter_input(INPUT_GET,'tsk',FILTER_SANITIZE_URL); |
||
| 24 | } |
||
| 25 | |||
| 26 | if (isset($_POST['archive'])) { |
||
| 27 | setcookie('archive','true'); |
||
| 28 | setcookie('archive_begin',strtotime($_POST['start_date'])); |
||
| 29 | setcookie('archive_end',strtotime($_POST['end_date'])); |
||
| 30 | setcookie('archive_speed',$_POST['archivespeed']); |
||
| 31 | } |
||
| 32 | if (isset($_POST['noarchive'])) { |
||
| 33 | setcookie('archive','false',-1); |
||
| 34 | setcookie('archive_begin','',-1); |
||
| 35 | setcookie('archive_end','',-1); |
||
| 36 | setcookie('archive_speed','',-1); |
||
| 37 | } |
||
| 38 | // When button "Remove all filters" is clicked |
||
| 39 | if (isset($_POST['removefilters'])) { |
||
| 40 | $allfilters = array_filter(array_keys($_COOKIE),function($key) { |
||
| 41 | return strpos($key,'filter_') === 0; |
||
| 42 | }); |
||
| 43 | foreach ($allfilters as $filt) { |
||
| 44 | unset($_COOKIE[$filt]); |
||
| 45 | setcookie($filt,null,-1); |
||
| 46 | } |
||
| 47 | } |
||
| 48 | ?> |
||
| 49 | <!DOCTYPE html> |
||
| 50 | <html> |
||
| 51 | <head> |
||
| 52 | <meta charset="UTF-8"> |
||
| 53 | <meta http-equiv="X-UA-Compatible" content="IE=10" /> |
||
| 54 | <title><?php print $title; ?> | <?php print $globalName; ?></title> |
||
| 55 | <meta name="keywords" content="<?php print $title; ?> spotter live flight tracking tracker map aircraft airline airport history database ads-b acars" /> |
||
| 56 | <meta name="description" content="<?php print $title; ?> | <?php print $globalName; ?> use FlightAirMap to track flight" /> |
||
| 57 | <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"> |
||
| 58 | <link rel="shortcut icon" type="image/x-icon" href="<?php print $globalURL; ?>/favicon.ico"> |
||
| 59 | <link rel="apple-touch-icon" href="<?php print $globalURL; ?>/images/touch-icon.png"> |
||
| 60 | <!--[if lt IE 9]> |
||
| 61 | <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script> |
||
| 62 | <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script> |
||
| 63 | <![endif]--> |
||
| 64 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/js/bootstrap-3.3.7-dist/css/bootstrap.min.css" /> |
||
| 65 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/css/jquery-ui.min.css" /> |
||
| 66 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/css/bootstrap-datetimepicker.min.css" /> |
||
| 67 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/css/font-awesome-4.7.0/css/font-awesome.min.css" /> |
||
| 68 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/css/bootstrap-select.min.css" /> |
||
| 69 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/css/style.css" /> |
||
| 70 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/css/print.css" /> |
||
| 71 | |||
| 72 | <script type="text/javascript" src="<?php print $globalURL; ?>/js/jquery-3.2.1.min.js"></script> |
||
| 73 | <script type="text/javascript" src="<?php print $globalURL; ?>/js/jquery-ui.min.js"></script> |
||
| 74 | |||
| 75 | <script type="text/javascript" src="<?php print $globalURL; ?>/js/moment.min.js"></script> |
||
| 76 | <script type="text/javascript" src="<?php print $globalURL; ?>/js/bootstrap-3.3.7-dist/js/bootstrap.min.js"></script> |
||
| 77 | <script type="text/javascript" src="<?php print $globalURL; ?>/js/bootstrap-datetimepicker.min.js"></script> |
||
| 78 | <script type="text/javascript" src="<?php print $globalURL; ?>/js/bootstrap-select.min.js"></script> |
||
| 79 | <script type="text/javascript" src="<?php print $globalURL; ?>/js/script.js"></script> |
||
| 80 | |||
| 81 | <?php |
||
| 82 | if (strtolower($current_page) == "about") |
||
| 83 | { |
||
| 84 | ?> |
||
| 85 | <link rel="stylesheet" href="<?php print $globalURL; ?>/css/leaflet.css" /> |
||
| 86 | <script src="<?php print $globalURL; ?>/js/leaflet.js"></script> |
||
| 87 | <?php |
||
| 88 | } |
||
| 89 | ?> |
||
| 90 | <?php |
||
| 91 | if (strtolower($current_page) == "search") |
||
| 92 | { |
||
| 93 | ?> |
||
| 94 | <script src="<?php print $globalURL; ?>/js/search.js"></script> |
||
| 95 | <?php |
||
| 96 | } |
||
| 97 | ?> |
||
| 98 | <?php |
||
| 99 | if (strtolower($current_page) == "index") |
||
| 100 | { |
||
| 101 | ?> |
||
| 102 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/css/style-map.css?<?php print date("H"); ?>" /> |
||
| 103 | <link rel="stylesheet" href="<?php print $globalURL; ?>/css/leaflet.css" /> |
||
| 104 | <link rel="stylesheet" href="<?php print $globalURL; ?>/css/leaflet-sidebar.css" /> |
||
| 105 | <script src="<?php print $globalURL; ?>/js/leaflet.js"></script> |
||
| 106 | <script src="<?php print $globalURL; ?>/js/leaflet.textpath.js"></script> |
||
| 107 | <script src="<?php print $globalURL; ?>/js/Marker.Rotate.js"></script> |
||
| 108 | <script src="<?php print $globalURL; ?>/js/MovingMarker.js"></script> |
||
| 109 | <script src="<?php print $globalURL; ?>/js/jquery.idle.min.js"></script> |
||
| 110 | <script src="<?php print $globalURL; ?>/js/jquery-sidebar.js"></script> |
||
| 111 | <script src="<?php print $globalURL; ?>/js/map.common.js"></script> |
||
| 112 | <?php |
||
| 113 | if (isset($_COOKIE['Map2DBuildings']) && $_COOKIE['Map2DBuildings'] == 'true') { |
||
| 114 | ?> |
||
| 115 | <script src="<?php print $globalURL; ?>/js/OSMBuildings-Leaflet.js"></script> |
||
| 116 | <?php |
||
| 117 | } |
||
| 118 | ?> |
||
| 119 | <?php |
||
| 120 | if ($globalMapProvider == 'MapboxGL' || (isset($_COOKIE['MapType']) && $_COOKIE['MapType'] == 'MapboxGL')) { |
||
| 121 | ?> |
||
| 122 | <link href="https://cdn.osmbuildings.org/mapbox-gl/0.40.0/mapbox-gl.css" rel='stylesheet' /> |
||
| 123 | <script src="https://cdn.osmbuildings.org/mapbox-gl/0.40.0/mapbox-gl.js"></script> |
||
| 124 | <script src="<?php print $globalURL; ?>/js/leaflet-mapbox-gl.js"></script> |
||
| 125 | <?php |
||
| 126 | } |
||
| 127 | ?> |
||
| 128 | <?php |
||
| 129 | if ((!isset($_COOKIE['MapFormat']) && isset($globalMap3Ddefault) && $globalMap3Ddefault) || (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] == '3d')) { |
||
| 130 | ?> |
||
| 131 | <?php |
||
| 132 | if (file_exists(dirname(__FILE__).'/js/Cesium/Cesium.js')) { |
||
| 133 | // || isset($globalOffline) && $globalOffline) { |
||
| 134 | ?> |
||
| 135 | <link rel="stylesheet" href="<?php print $globalURL; ?>/js/Cesium/Widgets/widgets.css" /> |
||
| 136 | <script src="<?php print $globalURL; ?>/js/Cesium/Cesium.js"></script> |
||
| 137 | <?php |
||
| 138 | } else { |
||
| 139 | ?> |
||
| 140 | <link rel="stylesheet" href="https://cesiumjs.org/releases/1.37/Build/Cesium/Widgets/widgets.css" /> |
||
| 141 | <script src="https://cesiumjs.org/releases/1.37/Build/Cesium/Cesium.js"></script> |
||
| 142 | <?php |
||
| 143 | } |
||
| 144 | ?> |
||
| 145 | <link rel="stylesheet" href="<?php print $globalURL; ?>/css/cesium-minimap.css" /> |
||
| 146 | <script src="<?php print $globalURL; ?>/js/cesium-minimap.js"></script> |
||
| 147 | <?php |
||
| 148 | } else { |
||
| 149 | ?> |
||
| 150 | <?php |
||
| 151 | if (isset($globalGoogleAPIKey) && $globalGoogleAPIKey != '' && ($MapType == 'Google-Roadmap' || $MapType == 'Google-Satellite' || $MapType == 'Google-Hybrid' || $MapType == 'Google-Terrain')) { |
||
| 152 | ?> |
||
| 153 | <script src="https://maps.google.com/maps/api/js?v=3&key=<?php print $globalGoogleAPIKey; ?>"></script> |
||
| 154 | <script src="<?php print $globalURL; ?>/js/leaflet-Google.js"></script> |
||
| 155 | <?php |
||
| 156 | } |
||
| 157 | ?> |
||
| 158 | <?php |
||
| 159 | if (isset($globalBingMapKey) && $globalBingMapKey != '') { |
||
| 160 | ?> |
||
| 161 | <!--<script src="https://cdn.polyfill.io/v2/polyfill.min.js?features=Promise"></script>--> |
||
| 162 | <script src="<?php print $globalURL; ?>/js/leaflet-Bing.js"></script> |
||
| 163 | <?php |
||
| 164 | } |
||
| 165 | ?> |
||
| 166 | <?php |
||
| 167 | if (isset($globalMapQuestKey) && $globalMapQuestKey != '' && ($MapType == 'MapQuest-OSM' || $MapType == 'MapQuest-Hybrid' || $MapType == 'MapQuest-Aerial')) { |
||
| 168 | ?> |
||
| 169 | <!--<script src="https://www.mapquestapi.com/sdk/leaflet/v2.2/mq-map.js?key=<?php print $globalMapQuestKey; ?>"></script>--> |
||
| 170 | <script src="https://open.mapquestapi.com/sdk/leaflet/v2.2/mq-map.js?key=<?php print $globalMapQuestKey; ?>"></script> |
||
| 171 | <?php |
||
| 172 | } |
||
| 173 | ?> |
||
| 174 | <?php |
||
| 175 | if (isset($globalHereappId) && $globalHereappId != '' && isset($globalHereappCode) && $globalHereappCode != '') { |
||
| 176 | ?> |
||
| 177 | <script src="<?php print $globalURL; ?>/js/leaflet-Here.js"></script> |
||
| 178 | <?php |
||
| 179 | } |
||
| 180 | ?> |
||
| 181 | <?php |
||
| 182 | if ($MapType == 'Yandex') { |
||
| 183 | ?> |
||
| 184 | <script src="https://api-maps.yandex.ru/2.0/?load=package.map&lang=en_US" type="text/javascript"></script> |
||
| 185 | <script src="<?php print $globalURL; ?>/js/leaflet-Yandex.js"></script> |
||
| 186 | <?php |
||
| 187 | } |
||
| 188 | } |
||
| 189 | ?> |
||
| 190 | <?php |
||
| 191 | if (isset($_POST['archive'])) { |
||
| 192 | ?> |
||
| 193 | <script src="<?php print $globalURL; ?>/js/map.common.js"></script> |
||
| 194 | <?php |
||
| 195 | if ((!isset($_COOKIE['MapFormat']) && (!isset($globalMap3Ddefault) || !$globalMap3Ddefault)) || (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] != '3d')) { |
||
| 196 | ?> |
||
| 197 | |||
| 198 | <script src="<?php print $globalURL; ?>/js/map.js.php?<?php print time(); ?>&archive&begindate=<?php print strtotime($_POST['start_date']); ?>&enddate=<?php print strtotime($_POST['end_date']); ?>&archivespeed=<?php print $_POST['archivespeed']; ?>"></script> |
||
| 199 | <?php |
||
| 200 | } |
||
| 201 | } else { |
||
| 202 | ?> |
||
| 203 | <?php |
||
| 204 | /* if (isset($globalBeta) && $globalBeta) { |
||
| 205 | ?> |
||
| 206 | <script src="<?php print $globalURL; ?>/js/leaflet-realtime.js"></script> |
||
| 207 | <script src="<?php print $globalURL; ?>/js/map.new.js.php?<?php print time(); ?>"></script> |
||
| 208 | <?php |
||
| 209 | } else { |
||
| 210 | */ |
||
| 211 | ?> |
||
| 212 | <?php |
||
| 213 | if ((!isset($_COOKIE['MapFormat']) && (!isset($globalMap3Ddefault) || !$globalMap3Ddefault)) || (isset($_COOKIE['MapFormat']) && $_COOKIE['MapFormat'] != '3d')) { |
||
| 214 | ?> |
||
| 215 | <?php |
||
| 216 | // if (isset($globalBeta) && $globalBeta) { |
||
| 217 | ?> |
||
| 218 | <script src="<?php print $globalURL; ?>/js/leaflet-playback.js"></script> |
||
| 219 | <?php |
||
| 220 | // } |
||
| 221 | ?> |
||
| 222 | <script src="<?php print $globalURL; ?>/js/map.2d.js.php?<?php print time(); ?><?php if (isset($tsk)) print '&tsk='.$tsk; ?>"></script> |
||
| 223 | <?php |
||
| 224 | if (!isset($globalAircraft) || $globalAircraft) { |
||
| 225 | ?> |
||
| 226 | <script src="<?php print $globalURL; ?>/js/map-aircraft.2d.js.php?<?php print time(); ?>"></script> |
||
| 227 | <?php |
||
| 228 | } |
||
| 229 | if (isset($globalTracker) && $globalTracker) { |
||
| 230 | ?> |
||
| 231 | <script src="<?php print $globalURL; ?>/js/map-tracker.2d.js.php?<?php print time(); ?>"></script> |
||
| 232 | <?php |
||
| 233 | } |
||
| 234 | if (isset($globalMarine) && $globalMarine) { |
||
| 235 | ?> |
||
| 236 | <script src="<?php print $globalURL; ?>/js/map-marine.2d.js.php?<?php print time(); ?>"></script> |
||
| 237 | <?php |
||
| 238 | } |
||
| 239 | if (isset($globalSatellite) && $globalSatellite) { |
||
| 240 | ?> |
||
| 241 | <script src="<?php print $globalURL; ?>/js/map-satellite.2d.js.php?<?php print time(); ?>"></script> |
||
| 242 | <?php |
||
| 243 | } |
||
| 244 | } |
||
| 245 | ?> |
||
| 246 | <?php |
||
| 247 | // } |
||
| 248 | ?> |
||
| 249 | <?php |
||
| 250 | } |
||
| 251 | } |
||
| 252 | ?> |
||
| 253 | <?php |
||
| 254 | //if ((strtolower($current_page) == "ident-detailed" && isset($ident)) || strtolower($current_page) == "flightid-overview") |
||
| 255 | //if ((strtolower($current_page) == "ident-detailed" && isset($ident) && isset($globalArchive) && $globalArchive)) |
||
| 256 | if ((strtolower($current_page) == "ident-detailed" && isset($ident) && isset($globalArchive) && $globalArchive)) |
||
| 257 | { |
||
| 258 | ?> |
||
| 259 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/css/style-map.css?<?php print date("H"); ?>" /> |
||
| 260 | <link rel="stylesheet" href="<?php print $globalURL; ?>/css/leaflet.css" /> |
||
| 261 | <link rel="stylesheet" href="<?php print $globalURL; ?>/css/leaflet-sidebar.css" /> |
||
| 262 | <script src="<?php print $globalURL; ?>/js/leaflet.js"></script> |
||
| 263 | <script src="<?php print $globalURL; ?>/js/Marker.Rotate.js"></script> |
||
| 264 | <script src="<?php print $globalURL; ?>/js/MovingMarker.js"></script> |
||
| 265 | <script src="<?php print $globalURL; ?>/js/jquery.idle.min.js"></script> |
||
| 266 | <script src="<?php print $globalURL; ?>/js/map.common.js"></script> |
||
| 267 | <script src="<?php print $globalURL; ?>/js/map.2d.js.php?ident=<?php print $ident; ?><?php if(isset($latitude)) print '&latitude='.$latitude; ?><?php if(isset($longitude)) print '&longitude='.$longitude; ?>&<?php print time(); ?>"></script> |
||
| 268 | <?php |
||
| 269 | if (!isset($type) || $type == 'aircraft') { |
||
| 270 | ?> |
||
| 271 | <script src="<?php print $globalURL; ?>/js/map-aircraft.2d.js.php?<?php print time(); ?>&ident=<?php print $ident; ?>"></script> |
||
| 272 | <?php |
||
| 273 | } elseif (isset($type) && $type == 'marine') { |
||
| 274 | ?> |
||
| 275 | <script src="<?php print $globalURL; ?>/js/map-marine.2d.js.php?<?php print time(); ?>&ident=<?php print $ident; ?>"></script> |
||
| 276 | <?php |
||
| 277 | } elseif (isset($type) && $type == 'tracker') { |
||
| 278 | ?> |
||
| 279 | <script src="<?php print $globalURL; ?>/js/map-tracker.2d.js.php?<?php print time(); ?>&ident=<?php print $ident; ?>"></script> |
||
| 280 | <?php |
||
| 281 | } elseif (isset($type) && $type == 'satellite') { |
||
| 282 | ?> |
||
| 283 | <script src="<?php print $globalURL; ?>/js/map-satellite.2d.js.php?<?php print time(); ?>&ident=<?php print $ident; ?>"></script> |
||
| 284 | <?php |
||
| 285 | } |
||
| 286 | ?> |
||
| 287 | <?php |
||
| 288 | if (isset($globalGoogleAPIKey) && $globalGoogleAPIKey != '' && ($MapType == 'Google-Roadmap' || $MapType == 'Google-Satellite' || $MapType == 'Google-Hybrid' || $MapType == 'Google-Terrain')) { |
||
| 289 | ?> |
||
| 290 | <script src="https://maps.google.com/maps/api/js?v=3&key=<?php print $globalGoogleAPIKey; ?>"></script> |
||
| 291 | <script src="<?php print $globalURL; ?>/js/leaflet-Google.js"></script> |
||
| 292 | <?php |
||
| 293 | } |
||
| 294 | ?> |
||
| 295 | <?php |
||
| 296 | if (isset($globalBingMapKey) && $globalBingMapKey != '') { |
||
| 297 | ?> |
||
| 298 | <!--<script src="https://cdn.polyfill.io/v2/polyfill.min.js?features=Promise"></script>--> |
||
| 299 | <script src="<?php print $globalURL; ?>/js/leaflet-Bing.js"></script> |
||
| 300 | <?php |
||
| 301 | } |
||
| 302 | ?> |
||
| 303 | <?php |
||
| 304 | if (isset($globalMapQuestKey) && $globalMapQuestKey != '' && ($MapType == 'MapQuest-OSM' || $MapType == 'MapQuest-Hybrid' || $MapType == 'MapQuest-Aerial')) { |
||
| 305 | ?> |
||
| 306 | <!--<script src="https://www.mapquestapi.com/sdk/leaflet/v2.2/mq-map.js?key=<?php print $globalMapQuestKey; ?>"></script>--> |
||
| 307 | <script src="https://open.mapquestapi.com/sdk/leaflet/v2.2/mq-map.js?key=<?php print $globalMapQuestKey; ?>"></script> |
||
| 308 | <?php |
||
| 309 | } |
||
| 310 | ?> |
||
| 311 | <?php |
||
| 312 | if (isset($globalHereappId) && $globalHereappId != '' && isset($globalHereappCode) && $globalHereappCode != '') { |
||
| 313 | ?> |
||
| 314 | <script src="<?php print $globalURL; ?>/js/leaflet-Here.js"></script> |
||
| 315 | <?php |
||
| 316 | } |
||
| 317 | ?> |
||
| 318 | <?php |
||
| 319 | if ($MapType == 'Yandex') { |
||
| 320 | ?> |
||
| 321 | <script src="http://api-maps.yandex.ru/2.0/?load=package.map&lang=en_US" type="text/javascript"></script> |
||
| 322 | <script src="<?php print $globalURL; ?>/js/leaflet-Yandex.js"></script> |
||
| 323 | <?php |
||
| 324 | } |
||
| 325 | ?> |
||
| 326 | <?php |
||
| 327 | } |
||
| 328 | |||
| 329 | if (strtolower($current_page) == "flightid-overview" && isset($globalArchive) && $globalArchive && isset($flightaware_id)) |
||
| 330 | { |
||
| 331 | ?> |
||
| 332 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/css/style-map.css?<?php print date("H"); ?>" /> |
||
| 333 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/css/leaflet.css" /> |
||
| 334 | <link type="text/css" rel="stylesheet" href="<?php print $globalURL; ?>/css/leaflet-sidebar.css" /> |
||
| 335 | <script src="<?php print $globalURL; ?>/js/leaflet.js"></script> |
||
| 336 | <script src="<?php print $globalURL; ?>/js/Marker.Rotate.js"></script> |
||
| 337 | <script src="<?php print $globalURL; ?>/js/MovingMarker.js"></script> |
||
| 338 | <script src="<?php print $globalURL; ?>/js/jquery.idle.min.js"></script> |
||
| 339 | <script src="<?php print $globalURL; ?>/js/map.common.js"></script> |
||
| 340 | <script src="<?php print $globalURL; ?>/js/map.2d.js.php?flightaware_id=<?php print $flightaware_id; ?><?php if(isset($latitude)) print '&latitude='.$latitude; ?><?php if(isset($longitude)) print '&longitude='.$longitude; ?>&<?php print time(); ?>"></script> |
||
| 341 | <script src="<?php print $globalURL; ?>/js/map-aircraft.2d.js.php?flightaware_id=<?php print $flightaware_id; ?>&<?php print time(); ?>"></script> |
||
| 342 | <?php |
||
| 343 | if (isset($globalGoogleAPIKey) && $globalGoogleAPIKey != '' && ($MapType == 'Google-Roadmap' || $MapType == 'Google-Satellite' || $MapType == 'Google-Hybrid' || $MapType == 'Google-Terrain')) { |
||
| 344 | ?> |
||
| 345 | <script src="https://maps.google.com/maps/api/js?v=3&key=<?php print $globalGoogleAPIKey; ?>"></script> |
||
| 346 | <script src="<?php print $globalURL; ?>/js/leaflet-Google.js"></script> |
||
| 347 | <?php |
||
| 348 | } |
||
| 349 | ?> |
||
| 350 | <?php |
||
| 351 | if (isset($globalBingMapKey) && $globalBingMapKey != '') { |
||
| 352 | ?> |
||
| 353 | <!--<script src="https://cdn.polyfill.io/v2/polyfill.min.js?features=Promise"></script>--> |
||
| 354 | <script src="<?php print $globalURL; ?>/js/leaflet-Bing.js"></script> |
||
| 355 | <?php |
||
| 356 | } |
||
| 357 | ?> |
||
| 358 | <?php |
||
| 359 | if (isset($globalMapQuestKey) && $globalMapQuestKey != '' && ($MapType == 'MapQuest-OSM' || $MapType == 'MapQuest-Hybrid' || $MapType == 'MapQuest-Aerial')) { |
||
| 360 | ?> |
||
| 361 | <!--<script src="https://www.mapquestapi.com/sdk/leaflet/v2.2/mq-map.js?key=<?php print $globalMapQuestKey; ?>"></script>--> |
||
| 362 | <script src="https://open.mapquestapi.com/sdk/leaflet/v2.2/mq-map.js?key=<?php print $globalMapQuestKey; ?>"></script> |
||
| 363 | <?php |
||
| 364 | } |
||
| 365 | ?> |
||
| 366 | <?php |
||
| 367 | if (isset($globalHereappId) && $globalHereappId != '' && isset($globalHereappCode) && $globalHereappCode != '') { |
||
| 368 | ?> |
||
| 369 | <script src="<?php print $globalURL; ?>/js/leaflet-Here.js"></script> |
||
| 370 | <?php |
||
| 371 | } |
||
| 372 | ?> |
||
| 373 | <?php |
||
| 374 | if ($MapType == 'Yandex') { |
||
| 375 | ?> |
||
| 376 | <script src="http://api-maps.yandex.ru/2.0/?load=package.map&lang=en_US" type="text/javascript"></script> |
||
| 377 | <script src="<?php print $globalURL; ?>/js/leaflet-Yandex.js"></script> |
||
| 378 | <?php |
||
| 379 | } |
||
| 380 | ?> |
||
| 381 | <?php |
||
| 382 | } |
||
| 383 | ?> |
||
| 384 | <?php |
||
| 385 | /* |
||
| 386 | if ($facebook_meta_image != "") |
||
| 387 | { |
||
| 388 | ?> |
||
| 389 | <meta property="og:image" content="<?php print $facebook_meta_image; ?>"/> |
||
| 390 | <?php |
||
| 391 | } else { |
||
| 392 | ?> |
||
| 393 | <meta property="og:image" content="<?php print $globalURL; ?>/images/touch-icon.png"/> |
||
| 394 | <?php |
||
| 395 | } |
||
| 396 | */ |
||
| 397 | ?> |
||
| 398 | <?php |
||
| 399 | if (isset($globalCustomCSS) && $globalCustomCSS != '') { |
||
| 400 | ?> |
||
| 401 | <link type="text/css" rel="stylesheet" href="<?php print $globalCustomCSS; ?>" /> |
||
| 402 | <?php |
||
| 403 | } |
||
| 404 | ?> |
||
| 405 | |||
| 406 | <meta property="og:title" content="<?php print $title; ?> | <?php print $globalName; ?>"/> |
||
| 407 | <meta property="og:url" content="<?php print $globalURL.$_SERVER['REQUEST_URI']; ?>"/> |
||
| 408 | <meta property="og:site_name" content="<?php print $globalName; ?>"/> |
||
| 409 | </head> |
||
| 410 | <body class="page-<?php print strtolower($current_page); ?>"> |
||
| 411 | <div class="navbar navbar-fixed-top" role="navigation"> |
||
| 412 | <div class="container"> |
||
| 413 | <div class="navbar-header"> |
||
| 414 | <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse"> |
||
| 415 | <span class="sr-only">Toggle navigation</span> |
||
| 416 | <span class="icon-bar"></span> |
||
| 417 | <span class="icon-bar"></span> |
||
| 418 | <span class="icon-bar"></span> |
||
| 419 | </button> |
||
| 420 | <a href="<?php print $globalURL; ?>/search" class="navbar-toggle navbar-toggle-search"><i class="fa fa-search"></i></a> |
||
| 421 | <a class="navbar-brand" href="<?php if ($globalURL == '') print '/'; else print $globalURL; ?>"><img src="<?php print $globalURL.$logoURL; ?>" height="30px" /></a> |
||
| 422 | </div> |
||
| 423 | <div class="collapse navbar-collapse"> |
||
| 424 | |||
| 425 | <ul class="nav navbar-nav"> |
||
| 426 | <?php |
||
| 427 | if (isset($globalNewsFeeds['global']) && !empty($globalNewsFeeds['global'])) { |
||
| 428 | ?> |
||
| 429 | <li><a href="<?php print $globalURL; ?>/news"><?php echo _("News"); ?></a></li> |
||
| 430 | <?php |
||
| 431 | } |
||
| 432 | ?> |
||
| 433 | |||
| 434 | <?php |
||
| 435 | $sub = false; |
||
| 436 | if ( |
||
| 437 | ( |
||
| 438 | (!isset($globalAircraft) || (isset($globalAircraft) && $globalAircraft === TRUE)) && ((isset($globalMarine) && $globalMarine === TRUE) || (isset($globalTracker) && $globalTracker === TRUE) || (isset($globalSatellite) && $globalSatellite === TRUE)) |
||
| 439 | ) || |
||
| 440 | ( |
||
| 441 | isset($globalMarine) && $globalMarine === TRUE && ((isset($globalTracker) && $globalTracker === TRUE) || (isset($globalSatellite) && $globalSatellite === TRUE)) |
||
| 442 | ) || |
||
| 443 | ( |
||
| 444 | isset($globalTracker) && $globalTracker === TRUE && ((isset($globalMarine) && $globalMarine === TRUE) || (isset($globalSatellite) && $globalSatellite === TRUE)) |
||
| 445 | ) || |
||
| 446 | ( |
||
| 447 | isset($globalSatellite) && $globalSatellite === TRUE && ((isset($globalMarine) && $globalMarine === TRUE) || (isset($globalTracker) && $globalTracker === TRUE)) |
||
| 448 | ) |
||
| 449 | ) { |
||
| 450 | $sub = true; |
||
| 451 | } |
||
| 452 | ?> |
||
| 453 | <?php |
||
| 454 | if (!isset($globalAircraft) || $globalAircraft === TRUE) { |
||
| 455 | ?> |
||
| 456 | <li class="dropdown"> |
||
| 457 | <?php |
||
| 458 | if ($sub) { |
||
| 459 | ?> |
||
| 460 | <li class="dropdown"> |
||
| 461 | <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php echo _("Aircrafts"); ?> <b class="caret"></b></a> |
||
| 462 | <ul class="dropdown-menu multi-level"> |
||
| 463 | <li class="dropdown-submenu"> |
||
| 464 | <?php |
||
| 465 | } |
||
| 466 | ?> |
||
| 467 | <?php |
||
| 468 | if (isset($globalNewsFeeds['aircraft']) && !empty($globalNewsFeeds['aircraft'])) { |
||
| 469 | ?> |
||
| 470 | <a href="<?php print $globalURL; ?>/news-aircraft"><?php echo _("Aircrafts News"); ?></a></li> |
||
| 471 | <li> |
||
| 472 | <?php |
||
| 473 | } |
||
| 474 | ?> |
||
| 475 | |||
| 476 | <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php echo _("Explore"); ?> <b class="<?php if ($sub) echo 'right-'; ?>caret"></b></a> |
||
| 477 | <ul class="dropdown-menu"> |
||
| 478 | <li><a href="<?php print $globalURL; ?>/aircraft"><?php echo _("Aircrafts Types"); ?></a></li> |
||
| 479 | <?php |
||
| 480 | if (!isset($globalNoAirlines) || $globalNoAirlines === FALSE) { |
||
| 481 | ?> |
||
| 482 | <li><a href="<?php print $globalURL; ?>/airline"><?php echo _("Airlines"); ?></a></li> |
||
| 483 | <?php |
||
| 484 | } |
||
| 485 | ?> |
||
| 486 | <li><a href="<?php print $globalURL; ?>/airport"><?php echo _("Airports"); ?></a></li> |
||
| 487 | <?php |
||
| 488 | if ((isset($globalUseOwner) && $globalUseOwner) || (!isset($globalUseOwner) && (!isset($globalVA) || !$globalVA) && (!isset($globalIVAO) || !$globalIVAO) && (!isset($globalVATSIM) || !$globalVATSIM) && (!isset($globalphpVMS) || !$globalphpVMS) && (!isset($globalVAM) || !$globalVAM))) { |
||
| 489 | ?> |
||
| 490 | <li><a href="<?php print $globalURL; ?>/owner"><?php echo _("Owners"); ?></a></li> |
||
| 491 | <?php |
||
| 492 | } |
||
| 493 | if ((isset($globalUsePilot) && $globalUsePilot) || !isset($globalUsePilot) && ((isset($globalVA) && $globalVA) || (isset($globalIVAO) && $globalIVAO) || (isset($globalVATSIM) && $globalVATSIM) || (isset($globalphpVMS) && $globalphpVMS) || (isset($globalVAM) && $globalVAM))) { |
||
| 494 | |||
| 495 | ?> |
||
| 496 | <li><a href="<?php print $globalURL; ?>/pilot"><?php echo _("Pilots"); ?></a></li> |
||
| 497 | <?php |
||
| 498 | } |
||
| 499 | ?> |
||
| 500 | <li><hr /></li> |
||
| 501 | <li><a href="<?php print $globalURL; ?>/currently"><?php echo _("Current Activity"); ?></a></li> |
||
| 502 | <li><a href="<?php print $globalURL; ?>/latest"><?php echo _("Latest Activity"); ?></a></li> |
||
| 503 | <li><a href="<?php print $globalURL; ?>/date/<?php print date("Y-m-d"); ?>"><?php echo _("Today's Activity"); ?></a></li> |
||
| 504 | <li><a href="<?php print $globalURL; ?>/newest"><?php echo _("Newest by Category"); ?></a></li> |
||
| 505 | <?php |
||
| 506 | if ($globalACARS) { |
||
| 507 | if (isset($globalDemo) && $globalDemo) { |
||
| 508 | ?> |
||
| 509 | <li><hr /></li> |
||
| 510 | <li><i><?php echo _('ACARS data not available publicly'); ?></i></li> |
||
| 511 | <li><a href=""><?php echo _('Latest ACARS messages'); ?></a></li> |
||
| 512 | <li><a href=""><?php echo _('Archive ACARS messages'); ?></a></li> |
||
| 513 | <?php |
||
| 514 | } else { |
||
| 515 | ?> |
||
| 516 | <li><hr /></li> |
||
| 517 | <li><a href="<?php print $globalURL; ?>/acars-latest"><?php echo _("Latest ACARS messages"); ?></a></li> |
||
| 518 | <li><a href="<?php print $globalURL; ?>/acars-archive"><?php echo _("Archive ACARS messages"); ?></a></li> |
||
| 519 | <?php |
||
| 520 | } |
||
| 521 | } |
||
| 522 | ?> |
||
| 523 | <?php |
||
| 524 | if (isset($globalAccidents) && $globalAccidents) { |
||
| 525 | ?> |
||
| 526 | <li><hr /></li> |
||
| 527 | <li><a href="<?php print $globalURL; ?>/accident-latest"><?php echo _("Latest accident"); ?></a></li> |
||
| 528 | <li><a href="<?php print $globalURL; ?>/accident/<?php print date("Y-m-d"); ?>"><?php echo _("Today's Accident"); ?></a></li> |
||
| 529 | <li><a href="<?php print $globalURL; ?>/incident-latest"><?php echo _("Latest incident"); ?></a></li> |
||
| 530 | <li><a href="<?php print $globalURL; ?>/incident/<?php print date("Y-m-d"); ?>"><?php echo _("Today's Incident"); ?></a></li> |
||
| 531 | <?php |
||
| 532 | } |
||
| 533 | ?> |
||
| 534 | <li><hr /></li> |
||
| 535 | <li><a href="<?php print $globalURL; ?>/highlights/table"><?php echo _("Special Highlights"); ?></a></li> |
||
| 536 | <?php |
||
| 537 | if (!isset($globalNoUpcoming) || $globalNoUpcoming === FALSE) { |
||
| 538 | ?> |
||
| 539 | <li><a href="<?php print $globalURL; ?>/upcoming"><?php echo _("Upcoming Flights"); ?></a></li> |
||
| 540 | <?php |
||
| 541 | } |
||
| 542 | ?> |
||
| 543 | </ul> |
||
| 544 | </li> |
||
| 545 | <li><a href="<?php print $globalURL; ?>/search"><?php echo _("Search"); ?></a></li> |
||
| 546 | <li><a href="<?php print $globalURL; ?>/statistics"><?php echo _("Statistics"); ?></a></li> |
||
| 547 | <li class="dropdown<?php if ($sub) echo '-submenu'; ?>"> |
||
| 548 | <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php echo _("Tools"); ?> <b class="<?php if ($sub) echo 'right-'; ?>caret"></b></a> |
||
| 549 | <ul class="dropdown-menu"> |
||
| 550 | <li><a href="<?php print $globalURL; ?>/tools/acars"><?php echo _("ACARS translator"); ?></a></li> |
||
| 551 | <li><a href="<?php print $globalURL; ?>/tools/metar"><?php echo _("METAR translator"); ?></a></li> |
||
| 552 | <li><a href="<?php print $globalURL; ?>/tools/notam"><?php echo _("NOTAM translator"); ?></a></li> |
||
| 553 | <?php |
||
| 554 | if (isset($globalGeoid) && $globalGeoid) { |
||
| 555 | ?> |
||
| 556 | <li><a href="<?php print $globalURL; ?>/tools/geoid"><?php echo _("Geoid Height Calculator"); ?></a></li> |
||
| 557 | <?php |
||
| 558 | } |
||
| 559 | ?> |
||
| 560 | </ul> |
||
| 561 | </li> |
||
| 562 | <?php |
||
| 563 | if ($sub) { |
||
| 564 | ?> |
||
| 565 | </li> |
||
| 566 | </ul> |
||
| 567 | <?php |
||
| 568 | } |
||
| 569 | } |
||
| 570 | ?> |
||
| 571 | <?php |
||
| 572 | if (isset($globalMarine) && $globalMarine) { |
||
| 573 | ?> |
||
| 574 | <li class="dropdown"> |
||
| 575 | <?php |
||
| 576 | if ($sub) { |
||
| 577 | ?> |
||
| 578 | <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php echo _("Marines"); ?> <b class="caret"></b></a> |
||
| 579 | <ul class="dropdown-menu multi-level"> |
||
| 580 | <li class="dropdown-submenu"> |
||
| 581 | <?php |
||
| 582 | } |
||
| 583 | ?> |
||
| 584 | <?php |
||
| 585 | if (isset($globalNewsFeeds['marine']) && !empty($globalNewsFeeds['marine'])) { |
||
| 586 | ?> |
||
| 587 | <a href="<?php print $globalURL; ?>/marine/news"><?php echo _("Marines News"); ?></a></li> |
||
| 588 | <li> |
||
| 589 | <?php |
||
| 590 | } |
||
| 591 | ?> |
||
| 592 | <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php echo _("Explore"); ?> <b class="<?php if ($sub) echo 'right-'; ?>caret"></b></a> |
||
| 593 | <ul class="dropdown-menu"> |
||
| 594 | <li><a href="<?php print $globalURL; ?>/marine/currently"><?php echo _("Current Activity"); ?></a></li> |
||
| 595 | <li><a href="<?php print $globalURL; ?>/marine/latest"><?php echo _("Latest Activity"); ?></a></li> |
||
| 596 | <li><a href="<?php print $globalURL; ?>/marine/date/<?php print date("Y-m-d"); ?>"><?php echo _("Today's Activity"); ?></a></li> |
||
| 597 | </ul> |
||
| 598 | <li><a href="<?php print $globalURL; ?>/marine/search"><?php echo _("Search"); ?></a></li> |
||
| 599 | <li><a href="<?php print $globalURL; ?>/marine/statistics"><?php echo _("Statistics"); ?></a></li> |
||
| 600 | </li> |
||
| 601 | <?php |
||
| 602 | if ($sub) { |
||
| 603 | ?> |
||
| 604 | </ul> |
||
| 605 | </li> |
||
| 606 | <?php |
||
| 607 | } |
||
| 608 | ?> |
||
| 609 | <?php |
||
| 610 | } |
||
| 611 | ?> |
||
| 612 | <?php |
||
| 613 | if (isset($globalTracker) && $globalTracker) { |
||
| 614 | ?> |
||
| 615 | <li class="dropdown"> |
||
| 616 | <?php |
||
| 617 | if ($sub) { |
||
| 618 | ?> |
||
| 619 | <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php echo _("Trackers"); ?> <b class="caret"></b></a> |
||
| 620 | <ul class="dropdown-menu multi-level"> |
||
| 621 | <li class="dropdown-submenu"> |
||
| 622 | <?php |
||
| 623 | } |
||
| 624 | ?> |
||
| 625 | <?php |
||
| 626 | if (isset($globalNewsFeeds['tracker']) && !empty($globalNewsFeeds['tracker'])) { |
||
| 627 | ?> |
||
| 628 | <a href="<?php print $globalURL; ?>/tracker/news"><?php echo _("Trackers News"); ?></a></li> |
||
| 629 | <li> |
||
| 630 | <?php |
||
| 631 | } |
||
| 632 | ?> |
||
| 633 | <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php echo _("Explore"); ?> <b class="<?php if ($sub) echo 'right-'; ?>caret"></b></a> |
||
| 634 | <ul class="dropdown-menu"> |
||
| 635 | <li><a href="<?php print $globalURL; ?>/tracker/currently"><?php echo _("Current Activity"); ?></a></li> |
||
| 636 | <li><a href="<?php print $globalURL; ?>/tracker/latest"><?php echo _("Latest Activity"); ?></a></li> |
||
| 637 | <li><a href="<?php print $globalURL; ?>/tracker/date/<?php print date("Y-m-d"); ?>"><?php echo _("Today's Activity"); ?></a></li> |
||
| 638 | </ul> |
||
| 639 | </li> |
||
| 640 | <li><a href="<?php print $globalURL; ?>/tracker/search"><?php echo _("Search"); ?></a></li> |
||
| 641 | <li><a href="<?php print $globalURL; ?>/tracker/statistics"><?php echo _("Statistics"); ?></a></li> |
||
| 642 | <?php |
||
| 643 | if ($sub) { |
||
| 644 | ?> |
||
| 645 | </ul> |
||
| 646 | </li> |
||
| 647 | <?php |
||
| 648 | } |
||
| 649 | ?> |
||
| 650 | <?php |
||
| 651 | } |
||
| 652 | ?> |
||
| 653 | <?php |
||
| 654 | if (isset($globalSatellite) && $globalSatellite) { |
||
| 655 | ?> |
||
| 656 | <li class="dropdown"> |
||
| 657 | <?php |
||
| 658 | if ($sub) { |
||
| 659 | ?> |
||
| 660 | <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php echo _("Satellites"); ?> <b class="caret"></b></a> |
||
| 661 | <ul class="dropdown-menu multi-level"> |
||
| 662 | <li class="dropdown-submenu"> |
||
| 663 | <?php |
||
| 664 | } |
||
| 665 | ?> |
||
| 666 | <?php |
||
| 667 | if (isset($globalNewsFeeds['satellite']) && !empty($globalNewsFeeds['satellite'])) { |
||
| 668 | ?> |
||
| 669 | <a href="<?php print $globalURL; ?>/marine/news"><?php echo _("Satellites News"); ?></a></li> |
||
| 670 | <li> |
||
| 671 | <?php |
||
| 672 | } |
||
| 673 | ?> |
||
| 674 | |||
| 675 | <!-- |
||
| 676 | <a href="#" class="dropdown-toggle" data-toggle="dropdown"><?php echo _("Explore"); ?> <b class="<?php if ($sub) echo 'right-'; ?>caret"></b></a> |
||
| 677 | <ul class="dropdown-menu"> |
||
| 678 | <li><a href="<?php print $globalURL; ?>/satellite/currently"><?php echo _("Current Activity"); ?></a></li> |
||
| 679 | <li><a href="<?php print $globalURL; ?>/satellite/latest"><?php echo _("Latest Activity"); ?></a></li> |
||
| 680 | <li><a href="<?php print $globalURL; ?>/satellite/date/<?php print date("Y-m-d"); ?>"><?php echo _("Today's Activity"); ?></a></li> |
||
| 681 | </ul> |
||
| 682 | </li> |
||
| 683 | --> |
||
| 684 | <li><a href="<?php print $globalURL; ?>/satellite/statistics"><?php echo _("Statistics"); ?></a></li> |
||
| 685 | <?php |
||
| 686 | if ($sub) { |
||
| 687 | ?> |
||
| 688 | </ul> |
||
| 689 | </li> |
||
| 690 | <?php |
||
| 691 | } |
||
| 692 | ?> |
||
| 693 | <?php |
||
| 694 | } |
||
| 695 | ?> |
||
| 696 | |||
| 697 | <li class="dropdown"> |
||
| 698 | <a href="<?php print $globalURL; ?>/about" class="dropdown-toggle" data-toggle="dropdown"><?php echo _("About"); ?> <b class="caret"></b></a> |
||
| 699 | <ul class="dropdown-menu"> |
||
| 700 | <li><a href="<?php print $globalURL; ?>/about"><?php echo _("About The Project"); ?></a></li> |
||
| 701 | <li><a href="<?php print $globalURL; ?>/about/export"><?php echo _("Exporting Data"); ?></a></li> |
||
| 702 | <?php |
||
| 703 | if (!isset($globalAircraft) || $globalAircraft === TRUE) { |
||
| 704 | ?> |
||
| 705 | <li><hr /></li> |
||
| 706 | <li><a href="<?php print $globalURL; ?>/about/tv"><?php echo _("Spotter TV"); ?></a></li> |
||
| 707 | <?php |
||
| 708 | } |
||
| 709 | ?> |
||
| 710 | <?php if (isset($globalContribute) && $globalContribute) { ?> |
||
| 711 | <li><hr /></li> |
||
| 712 | <li><a href="<?php print $globalURL; ?>/contribute"><?php echo _("Contribute"); ?></a></li> |
||
| 713 | <li><hr /></li> |
||
| 714 | <?php } ?> |
||
| 715 | <?php if ($globalName == 'FlightAirMap') { ?> |
||
| 716 | <li><hr /></li> |
||
| 717 | <li><a href="https://github.com/Ysurac/FlightAirMap/issues" target="_blank"><?php echo _("Report any Issues"); ?></a></li> |
||
| 718 | <?php } ?> |
||
| 719 | </ul> |
||
| 720 | </li> |
||
| 721 | </ul> |
||
| 722 | <?php |
||
| 723 | if (isset($globalTranslate) && $globalTranslate) { |
||
| 724 | ?> |
||
| 725 | <div class="language"> |
||
| 726 | <form> |
||
| 727 | <select class="selectpicker" data-width="120px" onchange="language(this);"> |
||
| 728 | <?php |
||
| 729 | $Language = new Language(); |
||
| 730 | $alllang = $Language->getLanguages(); |
||
| 731 | foreach ($alllang as $key => $lang) { |
||
| 732 | print '<option value="'.$key.'"'; |
||
| 733 | if (isset($_COOKIE['language']) && $_COOKIE['language'] == $key) print ' selected '; |
||
| 734 | print '>'.$lang[0].'</option>'; |
||
| 735 | } |
||
| 736 | ?> |
||
| 737 | </select> |
||
| 738 | </form> |
||
| 739 | </div> |
||
| 740 | <?php |
||
| 741 | } |
||
| 742 | ?> |
||
| 743 | <div class="search"> |
||
| 744 | <form action="<?php print $globalURL; ?>/search" method="get"> |
||
| 745 | <!--<input type="text" name="q" value="<?php if (isset($GET['q'])) { if ($_GET['q'] != ""){ print $_GET['q']; } else { print _("Search"); } } else { print _("Search"); } ?>" onfocus="if (this.value=='search'){this.value='';}" /><button type="submit"><i class="fa fa-search"></i></button>--> |
||
| 746 | <input type="text" name="callsign" value="<?php if (isset($GET['callsign'])) { if ($_GET['callsign'] != ""){ print $_GET['callsign']; } else { print _("Search"); } } else { print _("Search"); } ?>" onfocus="if (this.value=='search'){this.value='';}" /><button type="submit"><i class="fa fa-search"></i></button> |
||
| 747 | </form> |
||
| 748 | </div> |
||
| 749 | <div class="social"> |
||
| 750 | <!-- I'm not sociable --> |
||
| 751 | </div> |
||
| 752 | </div><!--/.nav-collapse --> |
||
| 753 | </div> |
||
| 754 | </div> |
||
| 755 | |||
| 756 | <?php |
||
| 757 | if (isset($top_header) && $top_header != "") |
||
| 758 | { |
||
| 759 | print '<div class="top-header container clear" role="main">'; |
||
| 760 | print '<img src="'.$globalURL.'/images/'.$top_header.'" alt="'.$title.'" title="'.$title.'" />'; |
||
| 761 | print '</div>'; |
||
| 762 | } |
||
| 763 | |||
| 764 | if (strtolower($current_page) =='ident-detailed' || strtolower($current_page) == 'flightid-overview') { |
||
| 765 | ?> |
||
| 766 | <div class="top-header clear" role="main"> |
||
| 767 | <?php |
||
| 768 | if (isset($longitude) && isset($latitude) && $longitude != 0 && $latitude != 0) { |
||
| 769 | ?> |
||
| 770 | <div id="archive-map"></div> |
||
| 771 | <?php |
||
| 772 | } |
||
| 773 | ?> |
||
| 774 | </div> |
||
| 775 | <?php |
||
| 776 | } |
||
| 777 | if ((strpos(strtolower($current_page),'airport-') !== false && strpos(strtolower($current_page),'statistics-') === false) || (strpos(strtolower($current_page),'route-') !== false && strpos(strtolower($current_page),'statistics-') === false)) |
||
| 778 | { |
||
| 779 | ?> |
||
| 780 | <div class="top-header clear" role="main"> |
||
| 781 | <div id="map"></div> |
||
| 782 | <link rel="stylesheet" href="<?php print $globalURL; ?>/css/leaflet.css" /> |
||
| 783 | <script src="<?php print $globalURL; ?>/js/leaflet.js"></script> |
||
| 784 | |||
| 785 | <script> |
||
| 786 | var map; |
||
| 787 | var zoom = 13; |
||
| 788 | //create the map |
||
| 789 | <?php |
||
| 790 | if (strpos(strtolower($current_page),'airport-') !== false && strpos(strtolower($current_page),'statistics-') === false && isset($airport_array[0]['latitude'])) { |
||
| 791 | ?> |
||
| 792 | map = L.map('map', { zoomControl:true }).setView([<?php print $airport_array[0]['latitude']; ?>,<?php print $airport_array[0]['longitude']; ?>], zoom); |
||
| 793 | <?php |
||
| 794 | } elseif (strpos(strtolower($current_page),'airport-') !== false && strpos(strtolower($current_page),'statistics-') === false) { |
||
| 795 | ?> |
||
| 796 | map = L.map('map', { zoomControl:true }); |
||
| 797 | <?php |
||
| 798 | } elseif (strpos(strtolower($current_page),'route-') !== false && strpos(strtolower($current_page),'statistics-') === false && isset($spotter_array[0]['departure_airport_latitude'])) { |
||
| 799 | ?> |
||
| 800 | map = L.map('map', { zoomControl:true }).setView([<?php print $spotter_array[0]['departure_airport_latitude']; ?>,<?php print $spotter_array[0]['arrival_airport_longitude']; ?>]); |
||
| 801 | var line = L.polyline([[<?php print $spotter_array[0]['departure_airport_latitude']; ?>, <?php print $spotter_array[0]['departure_airport_longitude']; ?>],[<?php print $spotter_array[0]['arrival_airport_latitude']; ?>, <?php print $spotter_array[0]['arrival_airport_longitude']; ?>]]).addTo(map); |
||
| 802 | map.fitBounds([[<?php print $spotter_array[0]['departure_airport_latitude']; ?>, <?php print $spotter_array[0]['departure_airport_longitude']; ?>],[<?php print $spotter_array[0]['arrival_airport_latitude']; ?>, <?php print $spotter_array[0]['arrival_airport_longitude']; ?>]]); |
||
| 803 | var departure_airport = L.marker([<?php print $spotter_array[0]['departure_airport_latitude']; ?>, <?php print $spotter_array[0]['departure_airport_longitude']; ?>], {icon: L.icon({iconUrl: '<?php print $globalURL; ?>/images/departure_airport.png',iconSize: [16,18],iconAnchor: [8,16]})}).addTo(map); |
||
| 804 | var arrival_airport = L.marker([<?php print $spotter_array[0]['arrival_airport_latitude']; ?>, <?php print $spotter_array[0]['arrival_airport_longitude']; ?>], {icon: L.icon({iconUrl: '<?php print $globalURL; ?>/images/arrival_airport.png',iconSize: [16,18],iconAnchor: [8,16]})}).addTo(map); |
||
| 805 | <?php |
||
| 806 | } elseif (strpos(strtolower($current_page),'route-') !== false && strpos(strtolower($current_page),'statistics-') === false && !isset($spotter_array[0]['departure_airport_latitude']) && isset($spotter_array[0]['latitude'])) { |
||
| 807 | ?> |
||
| 808 | map = L.map('map', { zoomControl:true }).setView([<?php print $spotter_array[0]['latitude']; ?>,<?php print $spotter_array[0]['longitude']; ?>]); |
||
| 809 | <?php |
||
| 810 | } elseif (!isset($spotter_array[0]['latitude']) && !isset($spotter_array[0]['longitude'])) { |
||
| 811 | ?> |
||
| 812 | map = L.map('map', { zoomControl:true }); |
||
| 813 | <?php |
||
| 814 | } |
||
| 815 | ?> |
||
| 816 | //initialize the layer group for the aircrft markers |
||
| 817 | var layer_data = L.layerGroup(); |
||
| 818 | |||
| 819 | //a few title layers |
||
| 820 | <?php |
||
| 821 | if ($globalMapProvider == 'Mapbox') { |
||
| 822 | ?> |
||
| 823 | L.tileLayer('https://{s}.tiles.mapbox.com/v4/{id}/{z}/{x}/{y}.png?access_token={token}', { |
||
| 824 | maxZoom: 18, |
||
| 825 | attribution: 'Map data © <a href="http://openstreetmap.org">OpenStreetMap</a> contributors, ' + |
||
| 826 | '<a href="http://creativecommons.org/licenses/by-sa/2.0/">CC-BY-SA</a>, ' + |
||
| 827 | 'Imagery © <a href="http://mapbox.com">Mapbox</a>', |
||
| 828 | id: '<?php print $globalMapboxId; ?>', |
||
| 829 | token : '<?php print $globalMapboxToken; ?>' |
||
| 830 | }).addTo(map); |
||
| 831 | <?php |
||
| 832 | } elseif ($globalMapProvider == 'Mapbox-GL') { |
||
| 833 | ?> |
||
| 834 | L.mapboxGL({ |
||
| 835 | accessToken: '<?php print $globalMapboxToken; ?>', |
||
| 836 | style: 'mapbox://styles/mapbox/bright-v8' |
||
| 837 | }).addTo(map); |
||
| 838 | <?php |
||
| 839 | } elseif ($globalMapProvider == 'MapQuest-OSM') { |
||
| 840 | ?> |
||
| 841 | L.tileLayer('http://otile1.mqcdn.com/tiles/1.0.0/map/{z}/{x}/{y}.png', { |
||
| 842 | maxZoom: 18, |
||
| 843 | attribution: 'Map data © <a href="http://openstreetmap.org">OpenStreetMap</a> contributors, ' + |
||
| 844 | '<a href="http://www.openstreetmap.org/copyright">Open Database Licence</a>, ' + |
||
| 845 | 'Tiles Courtesy of <a href="http://www.mapquest.com">MapQuest</a>' |
||
| 846 | }).addTo(map); |
||
| 847 | <?php |
||
| 848 | } elseif ($globalMapProvider == 'MapQuest-Aerial') { |
||
| 849 | ?> |
||
| 850 | L.tileLayer('http://otile1.mqcdn.com/tiles/1.0.0/sat/{z}/{x}/{y}.png', { |
||
| 851 | maxZoom: 18, |
||
| 852 | attribution: 'Map data © <a href="http://openstreetmap.org">OpenStreetMap</a> contributors, ' + |
||
| 853 | '<a href="http://www.openstreetmap.org/copyright">Open Database Licence</a>, ' + |
||
| 854 | 'Tiles Courtesy of <a href="http://www.mapquest.com">MapQuest</a>, Portions Courtesy NASA/JPL-Caltech and U.S. Depart. of Agriculture, Farm Service Agency"' |
||
| 855 | }).addTo(map); |
||
| 856 | <?php |
||
| 857 | } elseif ($globalMapProvider == 'Google-Roadmap') { |
||
| 858 | ?> |
||
| 859 | var googleLayer = new L.Google('ROADMAP'); |
||
| 860 | map.addLayer(googleLayer); |
||
| 861 | <?php |
||
| 862 | } elseif ($globalMapProvider == 'Google-Satellite') { |
||
| 863 | ?> |
||
| 864 | var googleLayer = new L.Google('SATELLITE'); |
||
| 865 | map.addLayer(googleLayer); |
||
| 866 | <?php |
||
| 867 | } elseif ($globalMapProvider == 'Google-Hybrid') { |
||
| 868 | ?> |
||
| 869 | var googleLayer = new L.Google('HYBRID'); |
||
| 870 | map.addLayer(googleLayer); |
||
| 871 | <?php |
||
| 872 | } elseif ($globalMapProvider == 'Google-Terrain') { |
||
| 873 | ?> |
||
| 874 | var googleLayer = new L.Google('Terrain'); |
||
| 875 | map.addLayer(googleLayer); |
||
| 876 | <?php |
||
| 877 | } elseif (isset($globalMapCustomLayer[$globalMapProvider])) { |
||
| 878 | $customid = $globalMapProvider; |
||
| 879 | ?> |
||
| 880 | L.tileLayer('<?php print $globalMapCustomLayer[$customid]['url']; ?>/{z}/{x}/{y}.png', { |
||
| 881 | maxZoom: <?php if (isset($globalMapCustomLayer[$customid]['maxZoom'])) print $globalMapCustomLayer[$customid]['maxZoom']; else print '18'; ?>, |
||
| 882 | minZoom: <?php if (isset($globalMapCustomLayer[$customid]['minZoom'])) print $globalMapCustomLayer[$customid]['minZoom']; else print '0'; ?>, |
||
| 883 | noWrap: <?php if (isset($globalMapWrap) && !$globalMapWrap) print 'false'; else print 'true'; ?>, |
||
| 884 | attribution: '<?php print $globalMapCustomLayer[$customid]['attribution']; ?>' |
||
| 885 | }).addTo(map); |
||
| 886 | <?php |
||
| 887 | } elseif ($globalMapProvider == 'offline' || (isset($globalMapOffline) && $globalMapOffline === TRUE)) { |
||
| 888 | ?> |
||
| 889 | var center = map.getCenter(); |
||
| 890 | map.options.crs = L.CRS.EPSG4326; |
||
| 891 | map.setView(center); |
||
| 892 | map._resetView(map.getCenter(), map.getZoom(), true); |
||
| 893 | L.tileLayer('<?php print $globalURL; ?>/js/Cesium/Assets/Textures/NaturalEarthII/{z}/{x}/{y}.jpg', { |
||
| 894 | minZoom: 0, |
||
| 895 | maxZoom: 5, |
||
| 896 | tms : true, |
||
| 897 | zindex : 3, |
||
| 898 | noWrap: <?php if (isset($globalMapWrap) && !$globalMapWrap) print 'false'; else print 'true'; ?>, |
||
| 899 | attribution: 'Natural Earth' |
||
| 900 | }).addTo(map); |
||
| 901 | <?php |
||
| 902 | //} elseif ($globalMapProvider == 'OpenStreetMap') { |
||
| 903 | } else { |
||
| 904 | ?> |
||
| 905 | L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', { |
||
| 906 | maxZoom: 18, |
||
| 907 | attribution: 'Map data © <a href="http://openstreetmap.org">OpenStreetMap</a> contributors, ' + |
||
| 908 | '<a href="http://www.openstreetmap.org/copyright">Open Database Licence</a>' |
||
| 909 | }).addTo(map); |
||
| 910 | |||
| 911 | <?php |
||
| 912 | } |
||
| 913 | ?> |
||
| 914 | </script> |
||
| 915 | </div> |
||
| 916 | <?php |
||
| 917 | } |
||
| 918 | |||
| 919 | ?> |
||
| 920 | |||
| 921 | <section class="container main-content <?php if (strtolower($current_page) == 'index') print 'index '; ?>clear"> |
||
| 922 |
If you suppress an error, we recommend checking for the error condition explicitly: