Completed
Push — master ( 51eb43...067d3c )
by Yannick
31:27
created
weather-json.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -9,18 +9,18 @@
 block discarded – undo
9 9
 	header('Content-disposition: attachment; filename="weather.json"');
10 10
 }
11 11
 header('Content-Type: text/javascript');
12
-$latitude = filter_input(INPUT_GET,'latitude',FILTER_SANITIZE_NUMBER_FLOAT,FILTER_FLAG_ALLOW_FRACTION);
13
-$longitude = filter_input(INPUT_GET,'longitude',FILTER_SANITIZE_NUMBER_FLOAT,FILTER_FLAG_ALLOW_FRACTION);
12
+$latitude = filter_input(INPUT_GET, 'latitude', FILTER_SANITIZE_NUMBER_FLOAT, FILTER_FLAG_ALLOW_FRACTION);
13
+$longitude = filter_input(INPUT_GET, 'longitude', FILTER_SANITIZE_NUMBER_FLOAT, FILTER_FLAG_ALLOW_FRACTION);
14 14
 if ($latitude == '' || $longitude == '') return '';
15 15
 //echo 'latitude : '.$latitude.' - longitude : '.$longitude."\n";
16
-$airports = $Spotter->closestAirports($latitude,$longitude,500);
16
+$airports = $Spotter->closestAirports($latitude, $longitude, 500);
17 17
 //print_r($airports);
18 18
 $METAR = new METAR();
19 19
 $Weather = new Weather();
20 20
 $i = 0;
21 21
 $ew = true;
22 22
 if (empty($airports)) return '';
23
-while($ew) {
23
+while ($ew) {
24 24
 	$met = $METAR->getMETAR($airports[$i]['icao']);
25 25
 	//print_r($met);
26 26
 	if (!empty($met)) {
Please login to merge, or discard this patch.