|
@@ -55,23 +55,23 @@ discard block |
|
|
block discarded – undo |
|
55
|
55
|
$min = true; |
|
56
|
56
|
$allhistory = false; |
|
57
|
57
|
$filter['source'] = array(); |
|
58
|
|
-if ((!isset($globalMapVAchoose) || $globalMapVAchoose) && isset($globalVATSIM) && $globalVATSIM && isset($_COOKIE['filter_ShowVATSIM']) && $_COOKIE['filter_ShowVATSIM'] == 'true') $filter['source'] = array_merge($filter['source'],array('vatsimtxt')); |
|
59
|
|
-if ((!isset($globalMapVAchoose) || $globalMapVAchoose) && isset($globalIVAO) && $globalIVAO && isset($_COOKIE['filter_ShowIVAO']) && $_COOKIE['filter_ShowIVAO'] == 'true') $filter['source'] = array_merge($filter['source'],array('whazzup')); |
|
60
|
|
-if ((!isset($globalMapVAchoose) || $globalMapVAchoose) && isset($globalphpVMS) && $globalphpVMS && isset($_COOKIE['filter_ShowVMS']) && $_COOKIE['filter_ShowVMS'] == 'true') $filter['source'] = array_merge($filter['source'],array('phpvmacars')); |
|
61
|
|
-if ((!isset($globalMapchoose) || $globalMapchoose) && isset($globalSBS1) && $globalSBS1 && isset($_COOKIE['filter_ShowSBS1']) && $_COOKIE['filter_ShowSBS1'] == 'true') $filter['source'] = array_merge($filter['source'],array('sbs','famaprs')); |
|
62
|
|
-if ((!isset($globalMapchoose) || $globalMapchoose) && isset($globalAPRS) && $globalAPRS && isset($_COOKIE['filter_ShowAPRS']) && $_COOKIE['filter_ShowAPRS'] == 'true') $filter['source'] = array_merge($filter['source'],array('aprs')); |
|
63
|
|
-if (isset($_COOKIE['filter_ident']) && $_COOKIE['filter_ident'] != '') $filter['ident'] = filter_var($_COOKIE['filter_ident'],FILTER_SANITIZE_STRING); |
|
64
|
|
-if (isset($_COOKIE['filter_Airlines']) && $_COOKIE['filter_Airlines'] != '') $filter['airlines'] = filter_var_array(explode(',',$_COOKIE['filter_Airlines']),FILTER_SANITIZE_STRING); |
|
65
|
|
-if (isset($_COOKIE['filter_Sources']) && $_COOKIE['filter_Sources'] != '') $filter['source_aprs'] = filter_var_array(explode(',',$_COOKIE['filter_Sources']),FILTER_SANITIZE_STRING); |
|
66
|
|
-if (isset($_COOKIE['filter_airlinestype']) && $_COOKIE['filter_airlinestype'] != 'all') $filter['airlinestype'] = filter_var($_COOKIE['filter_airlinestype'],FILTER_SANITIZE_STRING); |
|
67
|
|
-if (isset($_COOKIE['filter_alliance']) && $_COOKIE['filter_alliance'] != 'all') $filter['alliance'] = filter_var($_COOKIE['filter_alliance'],FILTER_SANITIZE_STRING); |
|
|
58
|
+if ((!isset($globalMapVAchoose) || $globalMapVAchoose) && isset($globalVATSIM) && $globalVATSIM && isset($_COOKIE['filter_ShowVATSIM']) && $_COOKIE['filter_ShowVATSIM'] == 'true') $filter['source'] = array_merge($filter['source'], array('vatsimtxt')); |
|
|
59
|
+if ((!isset($globalMapVAchoose) || $globalMapVAchoose) && isset($globalIVAO) && $globalIVAO && isset($_COOKIE['filter_ShowIVAO']) && $_COOKIE['filter_ShowIVAO'] == 'true') $filter['source'] = array_merge($filter['source'], array('whazzup')); |
|
|
60
|
+if ((!isset($globalMapVAchoose) || $globalMapVAchoose) && isset($globalphpVMS) && $globalphpVMS && isset($_COOKIE['filter_ShowVMS']) && $_COOKIE['filter_ShowVMS'] == 'true') $filter['source'] = array_merge($filter['source'], array('phpvmacars')); |
|
|
61
|
+if ((!isset($globalMapchoose) || $globalMapchoose) && isset($globalSBS1) && $globalSBS1 && isset($_COOKIE['filter_ShowSBS1']) && $_COOKIE['filter_ShowSBS1'] == 'true') $filter['source'] = array_merge($filter['source'], array('sbs', 'famaprs')); |
|
|
62
|
+if ((!isset($globalMapchoose) || $globalMapchoose) && isset($globalAPRS) && $globalAPRS && isset($_COOKIE['filter_ShowAPRS']) && $_COOKIE['filter_ShowAPRS'] == 'true') $filter['source'] = array_merge($filter['source'], array('aprs')); |
|
|
63
|
+if (isset($_COOKIE['filter_ident']) && $_COOKIE['filter_ident'] != '') $filter['ident'] = filter_var($_COOKIE['filter_ident'], FILTER_SANITIZE_STRING); |
|
|
64
|
+if (isset($_COOKIE['filter_Airlines']) && $_COOKIE['filter_Airlines'] != '') $filter['airlines'] = filter_var_array(explode(',', $_COOKIE['filter_Airlines']), FILTER_SANITIZE_STRING); |
|
|
65
|
+if (isset($_COOKIE['filter_Sources']) && $_COOKIE['filter_Sources'] != '') $filter['source_aprs'] = filter_var_array(explode(',', $_COOKIE['filter_Sources']), FILTER_SANITIZE_STRING); |
|
|
66
|
+if (isset($_COOKIE['filter_airlinestype']) && $_COOKIE['filter_airlinestype'] != 'all') $filter['airlinestype'] = filter_var($_COOKIE['filter_airlinestype'], FILTER_SANITIZE_STRING); |
|
|
67
|
+if (isset($_COOKIE['filter_alliance']) && $_COOKIE['filter_alliance'] != 'all') $filter['alliance'] = filter_var($_COOKIE['filter_alliance'], FILTER_SANITIZE_STRING); |
|
68
|
68
|
|
|
69
|
69
|
if (isset($globalMapPopup) && !$globalMapPopup && !(isset($_COOKIE['flightpopup']) && $_COOKIE['flightpopup'] == 'true')) { |
|
70
|
70
|
$min = true; |
|
71
|
71
|
} else $min = false; |
|
72
|
72
|
|
|
73
|
73
|
if (isset($_GET['ident'])) { |
|
74
|
|
- $ident = filter_input(INPUT_GET,'ident',FILTER_SANITIZE_STRING); |
|
|
74
|
+ $ident = filter_input(INPUT_GET, 'ident', FILTER_SANITIZE_STRING); |
|
75
|
75
|
if ($tracker) { |
|
76
|
76
|
$spotter_array = $TrackerLive->getLastLiveTrackerDataByIdent($ident); |
|
77
|
77
|
} elseif ($marine) { |
|
@@ -85,7 +85,7 @@ discard block |
|
|
block discarded – undo |
|
85
|
85
|
} |
|
86
|
86
|
$allhistory = true; |
|
87
|
87
|
} elseif (isset($_GET['flightaware_id'])) { |
|
88
|
|
- $flightaware_id = filter_input(INPUT_GET,'flightaware_id',FILTER_SANITIZE_STRING); |
|
|
88
|
+ $flightaware_id = filter_input(INPUT_GET, 'flightaware_id', FILTER_SANITIZE_STRING); |
|
89
|
89
|
$spotter_array = $SpotterLive->getLastLiveSpotterDataById($flightaware_id); |
|
90
|
90
|
if (empty($spotter_array)) { |
|
91
|
91
|
$from_archive = true; |
|
@@ -93,44 +93,44 @@ discard block |
|
|
block discarded – undo |
|
93
|
93
|
} |
|
94
|
94
|
$allhistory = true; |
|
95
|
95
|
} elseif (isset($_GET['famtrack_id'])) { |
|
96
|
|
- $famtrack_id = filter_input(INPUT_GET,'famtrack_id',FILTER_SANITIZE_STRING); |
|
|
96
|
+ $famtrack_id = filter_input(INPUT_GET, 'famtrack_id', FILTER_SANITIZE_STRING); |
|
97
|
97
|
$spotter_array = $TrackerLive->getLastLiveTrackerDataById($famtrack_id); |
|
98
|
98
|
$allhistory = true; |
|
99
|
99
|
} elseif (isset($_GET['fammarine_id'])) { |
|
100
|
|
- $fammarine_id = filter_input(INPUT_GET,'fammarine_id',FILTER_SANITIZE_STRING); |
|
|
100
|
+ $fammarine_id = filter_input(INPUT_GET, 'fammarine_id', FILTER_SANITIZE_STRING); |
|
101
|
101
|
$spotter_array = $MarineLive->getLastLiveMarineDataById($fammarine_id); |
|
102
|
102
|
$allhistory = true; |
|
103
|
103
|
} elseif (isset($_GET['coord']) && (!isset($globalMapPopup) || $globalMapPopup || (isset($_COOKIE['flightpopup']) && $_COOKIE['flightpopup'] == 'true'))) { |
|
104
|
104
|
//} elseif (isset($_GET['coord'])) { |
|
105
|
105
|
$usecoord = true; |
|
106
|
|
- $coord = explode(',',$_GET['coord']); |
|
|
106
|
+ $coord = explode(',', $_GET['coord']); |
|
107
|
107
|
if ($tracker) { |
|
108
|
|
- $spotter_array = $TrackerLive->getLiveTrackerDatabyCoord($coord,$filter); |
|
|
108
|
+ $spotter_array = $TrackerLive->getLiveTrackerDatabyCoord($coord, $filter); |
|
109
|
109
|
} elseif ($marine) { |
|
110
|
|
- $spotter_array = $MarineLive->getLiveMarineDatabyCoord($coord,$filter); |
|
|
110
|
+ $spotter_array = $MarineLive->getLiveMarineDatabyCoord($coord, $filter); |
|
111
|
111
|
} else { |
|
112
|
|
- $spotter_array = $SpotterLive->getLiveSpotterDatabyCoord($coord,$filter); |
|
|
112
|
+ $spotter_array = $SpotterLive->getLiveSpotterDatabyCoord($coord, $filter); |
|
113
|
113
|
} |
|
114
|
114
|
} elseif (isset($globalMapUseBbox) && $globalMapUseBbox && isset($_GET['coord']) && $min) { |
|
115
|
115
|
$usecoord = true; |
|
116
|
|
- $coord = explode(',',$_GET['coord']); |
|
|
116
|
+ $coord = explode(',', $_GET['coord']); |
|
117
|
117
|
if ($tracker) { |
|
118
|
|
- $spotter_array = $TrackerLive->getMinLiveTrackerDatabyCoord($coord,$filter); |
|
|
118
|
+ $spotter_array = $TrackerLive->getMinLiveTrackerDatabyCoord($coord, $filter); |
|
119
|
119
|
} elseif ($marine) { |
|
120
|
|
- $spotter_array = $MarineLive->getMinLiveMarineDatabyCoord($coord,$filter); |
|
|
120
|
+ $spotter_array = $MarineLive->getMinLiveMarineDatabyCoord($coord, $filter); |
|
121
|
121
|
} else { |
|
122
|
|
- $spotter_array = $SpotterLive->getMinLiveSpotterDatabyCoord($coord,$filter); |
|
|
122
|
+ $spotter_array = $SpotterLive->getMinLiveSpotterDatabyCoord($coord, $filter); |
|
123
|
123
|
} |
|
124
|
124
|
} elseif (isset($_GET['archive']) && isset($_GET['begindate']) && isset($_GET['enddate']) && isset($_GET['speed']) && !isset($_GET['tracker']) && !isset($_GET['marine'])) { |
|
125
|
125
|
$from_archive = true; |
|
126
|
126
|
// $begindate = filter_input(INPUT_GET,'begindate',FILTER_VALIDATE_REGEXP,array("options"=>array("regexp"=>'~^\d{4}/\d{2}/\d{2}$~'))); |
|
127
|
127
|
// $enddate = filter_input(INPUT_GET,'enddate',FILTER_VALIDATE_REGEXP,array("options"=>array("regexp"=>'~^\d{4}/\d{2}/\d{2}$~'))); |
|
128
|
|
- $begindate = filter_input(INPUT_GET,'begindate',FILTER_SANITIZE_NUMBER_INT); |
|
129
|
|
- $enddate = filter_input(INPUT_GET,'enddate',FILTER_SANITIZE_NUMBER_INT); |
|
130
|
|
- $archivespeed = filter_input(INPUT_GET,'speed',FILTER_SANITIZE_NUMBER_INT); |
|
131
|
|
- $begindate = date('Y-m-d H:i:s',$begindate); |
|
132
|
|
- $enddate = date('Y-m-d H:i:s',$enddate); |
|
133
|
|
- $spotter_array = $SpotterArchive->getMinLiveSpotterData($begindate,$enddate,$filter); |
|
|
128
|
+ $begindate = filter_input(INPUT_GET, 'begindate', FILTER_SANITIZE_NUMBER_INT); |
|
|
129
|
+ $enddate = filter_input(INPUT_GET, 'enddate', FILTER_SANITIZE_NUMBER_INT); |
|
|
130
|
+ $archivespeed = filter_input(INPUT_GET, 'speed', FILTER_SANITIZE_NUMBER_INT); |
|
|
131
|
+ $begindate = date('Y-m-d H:i:s', $begindate); |
|
|
132
|
+ $enddate = date('Y-m-d H:i:s', $enddate); |
|
|
133
|
+ $spotter_array = $SpotterArchive->getMinLiveSpotterData($begindate, $enddate, $filter); |
|
134
|
134
|
} elseif ($min) { |
|
135
|
135
|
if ($tracker) { |
|
136
|
136
|
$spotter_array = $TrackerLive->getMinLiveTrackerData($filter); |
|
@@ -142,18 +142,18 @@ discard block |
|
|
block discarded – undo |
|
142
|
142
|
# $min = true; |
|
143
|
143
|
} else { |
|
144
|
144
|
if ($tracker) { |
|
145
|
|
- $spotter_array = $TrackerLive->getLiveTrackerData('','',$filter); |
|
|
145
|
+ $spotter_array = $TrackerLive->getLiveTrackerData('', '', $filter); |
|
146
|
146
|
} elseif ($marine) { |
|
147
|
|
- $spotter_array = $marineLive->getLiveMarineData('','',$filter); |
|
|
147
|
+ $spotter_array = $marineLive->getLiveMarineData('', '', $filter); |
|
148
|
148
|
} else { |
|
149
|
|
- $spotter_array = $SpotterLive->getLiveSpotterData('','',$filter); |
|
|
149
|
+ $spotter_array = $SpotterLive->getLiveSpotterData('', '', $filter); |
|
150
|
150
|
} |
|
151
|
151
|
} |
|
152
|
152
|
|
|
153
|
153
|
if (!empty($spotter_array) || $usecoord) { |
|
154
|
154
|
if ($usecoord) { |
|
155
|
155
|
if (isset($_GET['archive'])) { |
|
156
|
|
- $flightcnt = $SpotterArchive->getLiveSpotterCount($begindate,$enddate,$filter); |
|
|
156
|
+ $flightcnt = $SpotterArchive->getLiveSpotterCount($begindate, $enddate, $filter); |
|
157
|
157
|
} else { |
|
158
|
158
|
$flightcnt = $SpotterLive->getLiveSpotterCount($filter); |
|
159
|
159
|
} |
|
@@ -161,7 +161,7 @@ discard block |
|
|
block discarded – undo |
|
161
|
161
|
if ($flightcnt == '') $flightcnt = 0; |
|
162
|
162
|
} else $flightcnt = 0; |
|
163
|
163
|
|
|
164
|
|
-$sqltime = round(microtime(true)-$begintime,2); |
|
|
164
|
+$sqltime = round(microtime(true) - $begintime, 2); |
|
165
|
165
|
|
|
166
|
166
|
if ((!isset($_COOKIE['flightestimation']) && isset($globalMapEstimation) && $globalMapEstimation == FALSE) || (isset($_COOKIE['flightestimation']) && $_COOKIE['flightestimation'] == 'false')) $usenextlatlon = false; |
|
167
|
167
|
else $usenextlatlon = true; |
|
@@ -178,7 +178,7 @@ discard block |
|
|
block discarded – undo |
|
178
|
178
|
if (!empty($spotter_array) && is_array($spotter_array)) |
|
179
|
179
|
{ |
|
180
|
180
|
$output .= '"features": ['; |
|
181
|
|
- foreach($spotter_array as $spotter_item) |
|
|
181
|
+ foreach ($spotter_array as $spotter_item) |
|
182
|
182
|
{ |
|
183
|
183
|
$j++; |
|
184
|
184
|
date_default_timezone_set('UTC'); |
|
@@ -243,7 +243,7 @@ discard block |
|
|
block discarded – undo |
|
243
|
243
|
if (isset($spotter_item['registration'])) $output .= '"registration": "'.$spotter_item['registration'].'",'; |
|
244
|
244
|
if (isset($spotter_item['aircraft_name']) && isset($spotter_item['aircraft_type'])) { |
|
245
|
245
|
$output .= '"aircraft_name": "'.$spotter_item['aircraft_name'].' ('.$spotter_item['aircraft_type'].')",'; |
|
246
|
|
- $output .= '"aircraft_wiki": "http://'.strtolower($globalLanguage).'.wikipedia.org/wiki/'.urlencode(str_replace(' ','_',$spotter_item['aircraft_name'])).'",'; |
|
|
246
|
+ $output .= '"aircraft_wiki": "http://'.strtolower($globalLanguage).'.wikipedia.org/wiki/'.urlencode(str_replace(' ', '_', $spotter_item['aircraft_name'])).'",'; |
|
247
|
247
|
} elseif (isset($spotter_item['aircraft_type'])) { |
|
248
|
248
|
$output .= '"aircraft_name": "NA ('.$spotter_item['aircraft_type'].')",'; |
|
249
|
249
|
} elseif (!$min) { |
|
@@ -383,16 +383,16 @@ discard block |
|
|
block discarded – undo |
|
383
|
383
|
else $output .= '"heading": "'.$spotter_item['heading'].'",'; |
|
384
|
384
|
|
|
385
|
385
|
if (isset($archivespeed)) { |
|
386
|
|
- $nextcoord = $Common->nextcoord($spotter_item['latitude'],$spotter_item['longitude'],$spotter_item['ground_speed'],$spotter_item['heading'],$archivespeed); |
|
|
386
|
+ $nextcoord = $Common->nextcoord($spotter_item['latitude'], $spotter_item['longitude'], $spotter_item['ground_speed'], $spotter_item['heading'], $archivespeed); |
|
387
|
387
|
$output .= '"nextlatlon": ['.$nextcoord['latitude'].','.$nextcoord['longitude'].'],'; |
|
388
|
388
|
} elseif ($usenextlatlon) { |
|
389
|
|
- $nextcoord = $Common->nextcoord($spotter_item['latitude'],$spotter_item['longitude'],$spotter_item['ground_speed'],$spotter_item['heading']); |
|
|
389
|
+ $nextcoord = $Common->nextcoord($spotter_item['latitude'], $spotter_item['longitude'], $spotter_item['ground_speed'], $spotter_item['heading']); |
|
390
|
390
|
$output .= '"nextlatlon": ['.$nextcoord['latitude'].','.$nextcoord['longitude'].'],'; |
|
391
|
391
|
} |
|
392
|
392
|
|
|
393
|
393
|
if (!$min) $output .= '"image": "'.$image.'",'; |
|
394
|
394
|
if (isset($spotter_item['image_copyright']) && $spotter_item['image_copyright'] != '') { |
|
395
|
|
- $output .= '"image_copyright": "'.str_replace('"',"'",trim(str_replace(array("\r\n","\r","\n","\\r","\\n","\\r\\n"),'',$spotter_item['image_copyright']))).'",'; |
|
|
395
|
+ $output .= '"image_copyright": "'.str_replace('"', "'", trim(str_replace(array("\r\n", "\r", "\n", "\\r", "\\n", "\\r\\n"), '', $spotter_item['image_copyright']))).'",'; |
|
396
|
396
|
} |
|
397
|
397
|
if (isset($spotter_item['image_source_website'])) { |
|
398
|
398
|
$output .= '"image_source_website": "'.urlencode($spotter_item['image_source_website']).'",'; |
|
@@ -414,7 +414,7 @@ discard block |
|
|
block discarded – undo |
|
414
|
414
|
$output .= '"waypoints": "'.$spotter_item['waypoints'].'",'; |
|
415
|
415
|
} |
|
416
|
416
|
if (isset($spotter_item['acars'])) { |
|
417
|
|
- $output .= '"acars": "'.trim(str_replace(array("\r\n","\r","\n","\\r","\\n","\\r\\n"), '<br />',$spotter_item['acars']['message'])).'",'; |
|
|
417
|
+ $output .= '"acars": "'.trim(str_replace(array("\r\n", "\r", "\n", "\\r", "\\n", "\\r\\n"), '<br />', $spotter_item['acars']['message'])).'",'; |
|
418
|
418
|
} |
|
419
|
419
|
// type when not aircraft ? |
|
420
|
420
|
if (isset($spotter_item['type'])) { |
|
@@ -492,7 +492,7 @@ discard block |
|
|
block discarded – undo |
|
492
|
492
|
|
|
493
|
493
|
} |
|
494
|
494
|
*/ |
|
495
|
|
- $history = filter_input(INPUT_GET,'history',FILTER_SANITIZE_STRING); |
|
|
495
|
+ $history = filter_input(INPUT_GET, 'history', FILTER_SANITIZE_STRING); |
|
496
|
496
|
if ($history == '' && isset($_COOKIE['history'])) $history = $_COOKIE['history']; |
|
497
|
497
|
|
|
498
|
498
|
if ( |
|
@@ -500,7 +500,7 @@ discard block |
|
|
block discarded – undo |
|
500
|
500
|
|| ((isset($globalMapHistory) && $globalMapHistory) || $allhistory) |
|
501
|
501
|
// || (isset($history) && $history != '' && $history != 'NA' && ($history == $spotter_item['ident'] || $history == $spotter_item['flightaware_id'])) |
|
502
|
502
|
// || (isset($history) && $history != '' && $history != 'NA' && $history == $spotter_item['ident']) |
|
503
|
|
- || (isset($history) && $history != '' && $history != 'NA' && str_replace('-','',$history) == str_replace('-','',$spotter_item['flightaware_id'])) |
|
|
503
|
+ || (isset($history) && $history != '' && $history != 'NA' && str_replace('-', '', $history) == str_replace('-', '', $spotter_item['flightaware_id'])) |
|
504
|
504
|
|| (isset($history) && $history == '' && isset($_GET['flightaware_id']) && $_GET['flightaware_id'] == $spotter_item['flightaware_id']) |
|
505
|
505
|
) { |
|
506
|
506
|
if ($tracker) { |
|
@@ -529,9 +529,9 @@ discard block |
|
|
block discarded – undo |
|
529
|
529
|
else $output_history = '{"type": "Feature","properties": {"callsign": "'.$spotter_item['ident'].'","type": "history","altitude": "'.$alt.'"},"geometry": {"type": "LineString","coordinates": ['; |
|
530
|
530
|
} |
|
531
|
531
|
$output_history .= '['; |
|
532
|
|
- $output_history .= $spotter_history['longitude'].', '; |
|
533
|
|
- $output_history .= $spotter_history['latitude'].', '; |
|
534
|
|
- $output_history .= $spotter_history['altitude']*30.48; |
|
|
532
|
+ $output_history .= $spotter_history['longitude'].', '; |
|
|
533
|
+ $output_history .= $spotter_history['latitude'].', '; |
|
|
534
|
+ $output_history .= $spotter_history['altitude']*30.48; |
|
535
|
535
|
$output_history .= '],'; |
|
536
|
536
|
/* |
|
537
|
537
|
if ($from_archive === false) { |
|
@@ -549,8 +549,8 @@ discard block |
|
|
block discarded – undo |
|
549
|
549
|
else $output_history = '{"type": "Feature","properties": {"callsign": "'.$spotter_item['ident'].'","type": "history"},"geometry": {"type": "LineString","coordinates": ['; |
|
550
|
550
|
} else $d = true; |
|
551
|
551
|
$output_history .= '['; |
|
552
|
|
- $output_history .= $spotter_history['longitude'].', '; |
|
553
|
|
- $output_history .= $spotter_history['latitude']; |
|
|
552
|
+ $output_history .= $spotter_history['longitude'].', '; |
|
|
553
|
+ $output_history .= $spotter_history['latitude']; |
|
554
|
554
|
$output_history .= '],'; |
|
555
|
555
|
/* |
|
556
|
556
|
if ($from_archive === false) { |
|
@@ -566,9 +566,9 @@ discard block |
|
|
block discarded – undo |
|
566
|
566
|
|
|
567
|
567
|
if ($from_archive === false) { |
|
568
|
568
|
$output_historyd = '['; |
|
569
|
|
- $output_historyd .= $spotter_item['longitude'].', '; |
|
570
|
|
- $output_historyd .= $spotter_item['latitude']; |
|
571
|
|
- if (isset($spotter_history['altitude'])) $output_historyd .= ','.$spotter_item['altitude']*30.48; |
|
|
569
|
+ $output_historyd .= $spotter_item['longitude'].', '; |
|
|
570
|
+ $output_historyd .= $spotter_item['latitude']; |
|
|
571
|
+ if (isset($spotter_history['altitude'])) $output_historyd .= ','.$spotter_item['altitude']*30.48; |
|
572
|
572
|
$output_historyd .= '],'; |
|
573
|
573
|
//$output_history = $output_historyd.$output_history; |
|
574
|
574
|
$output_history = $output_history.$output_historyd; |
|
@@ -608,7 +608,7 @@ discard block |
|
|
block discarded – undo |
|
608
|
608
|
$output = substr($output, 0, -1); |
|
609
|
609
|
$output .= ']'; |
|
610
|
610
|
$output .= ',"initial_sqltime": "'.$sqltime.'",'; |
|
611
|
|
- $output .= '"totaltime": "'.round(microtime(true)-$begintime,2).'",'; |
|
|
611
|
+ $output .= '"totaltime": "'.round(microtime(true) - $begintime, 2).'",'; |
|
612
|
612
|
if (isset($begindate)) $output .= '"archive_date": "'.$begindate.'",'; |
|
613
|
613
|
$output .= '"fc": "'.$j.'"'; |
|
614
|
614
|
} else { |