Completed
Push — master ( f6e401...19913c )
by Yannick
10:24
created
tv.php 1 patch
Braces   +9 added lines, -3 removed lines patch added patch discarded remove patch
@@ -41,7 +41,9 @@  discard block
 block discarded – undo
41 41
 {
42 42
 	if (isset($globalTimezone)) {
43 43
 		date_default_timezone_set($globalTimezone);
44
-	} else date_default_timezone_set('UTC');
44
+	} else {
45
+		date_default_timezone_set('UTC');
46
+	}
45 47
 	print '<tr>';
46 48
 	if (isset($_GET['image']) && $_GET['image'] == "true")
47 49
 	{
@@ -98,10 +100,14 @@  discard block
 block discarded – undo
98 100
 	print '</div>';
99 101
 	print '<div class="other2">';
100 102
 	print '<span><i class="fa fa-arrow-up"></i> '.$spotter_item['departure_airport_city'].', '.$spotter_item['departure_airport_name'].', '.$spotter_item['departure_airport_country'];
101
-	if (isset($spotter_item['departure_airport_time']) && $spotter_item['departure_airport_time'] != '') print ' ('.$spotter_item['departure_airport_time'].')';
103
+	if (isset($spotter_item['departure_airport_time']) && $spotter_item['departure_airport_time'] != '') {
104
+		print ' ('.$spotter_item['departure_airport_time'].')';
105
+	}
102 106
 	print '</span>';
103 107
 	print '<span><i class="fa fa-arrow-down"></i> '.$spotter_item['arrival_airport_city'].', '.$spotter_item['arrival_airport_name'].', '.$spotter_item['arrival_airport_country'];
104
-	if (isset($spotter_item['arrival_airport_time']) && $spotter_item['arrival_airport_time'] != '') print ' ('.$spotter_item['arrival_airport_time'].')';
108
+	if (isset($spotter_item['arrival_airport_time']) && $spotter_item['arrival_airport_time'] != '') {
109
+		print ' ('.$spotter_item['arrival_airport_time'].')';
110
+	}
105 111
 	print '</span>';
106 112
 	print '</div>';
107 113
 	print '<div class="other3">';
Please login to merge, or discard this patch.
flightid-overview.php 1 patch
Braces   +10 added lines, -4 removed lines patch added patch discarded remove patch
@@ -51,7 +51,9 @@  discard block
 block discarded – undo
51 51
 		
52 52
 		if (isset($globalTimezone)) {
53 53
 			date_default_timezone_set($globalTimezone);
54
-		} else date_default_timezone_set('UTC');
54
+		} else {
55
+			date_default_timezone_set('UTC');
56
+		}
55 57
 		
56 58
 		//date_default_timezone_set('UTC');
57 59
 		if (is_array($all_data) && count($all_data) > 0) {
@@ -300,9 +302,13 @@  discard block
 block discarded – undo
300 302
 			print '<div>';
301 303
 			if (isset($spotter_item['pilot_id']) && $spotter_item['pilot_id'] != "")
302 304
 			{
303
-				if ($spotter_item['format_source'] == 'whazzup') print '<a href="https://www.ivao.aero/Member.aspx?ID='.$spotter_item['pilot_id'].'">'.$spotter_item['pilot_name'].' ('.$spotter_item['pilot_id'].')</a>';
304
-				elseif ($spotter_item['format_source'] == 'vatsimtxt') print '<a href="http://www.vataware.com/pilot/'.$spotter_item['pilot_id'].'">'.$spotter_item['pilot_name'].' ('.$spotter_item['pilot_id'].')</a>';
305
-				else print $spotter_item['pilot_name'].' ('.$spotter_item['pilot_id'].')';
305
+				if ($spotter_item['format_source'] == 'whazzup') {
306
+					print '<a href="https://www.ivao.aero/Member.aspx?ID='.$spotter_item['pilot_id'].'">'.$spotter_item['pilot_name'].' ('.$spotter_item['pilot_id'].')</a>';
307
+				} elseif ($spotter_item['format_source'] == 'vatsimtxt') {
308
+					print '<a href="http://www.vataware.com/pilot/'.$spotter_item['pilot_id'].'">'.$spotter_item['pilot_name'].' ('.$spotter_item['pilot_id'].')</a>';
309
+				} else {
310
+					print $spotter_item['pilot_name'].' ('.$spotter_item['pilot_id'].')';
311
+				}
306 312
 			} else {
307 313
 				if (isset($spotter_item['pilot_name']) && $spotter_item['pilot_name'] != "")
308 314
 				{
Please login to merge, or discard this patch.
registration-statistics-arrival-airport-country.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,7 +8,9 @@
 block discarded – undo
8 8
 if ($registration != '') {
9 9
 	$spotter_array = $Spotter->getSpotterDataByRegistration($registration, "0,1", $sort);
10 10
 	$aircraft_array = $Spotter->getAircraftInfoByRegistration($registration);
11
-} else $spotter_array=array();
11
+} else {
12
+	$spotter_array=array();
13
+}
12 14
 
13 15
 
14 16
 if (!empty($spotter_array))
Please login to merge, or discard this patch.
search-csv.php 1 patch
Braces   +18 added lines, -7 removed lines patch added patch discarded remove patch
@@ -16,8 +16,12 @@  discard block
 block discarded – undo
16 16
         } else if($_GET['start_date'] == "" && $_GET['end_date'] != ""){
17 17
                 $end_date = date("Y-m-d H:i:s", strtotime("2014-04-12")).",".$_GET['end_date'].":00";
18 18
                 $sql_date = $end_date;
19
-        } else $sql_date = '';
20
-} else $sql_date = '';
19
+        } else {
20
+        	$sql_date = '';
21
+        }
22
+        } else {
23
+	$sql_date = '';
24
+}
21 25
 
22 26
 if (isset($_GET['highest_altitude'])) {
23 27
         //for altitude manipulation
@@ -31,8 +35,12 @@  discard block
 block discarded – undo
31 35
         } else if($_GET['highest_altitude'] == "" && $_GET['lowest_altitude'] != ""){
32 36
                 $start_altitude = $_GET['lowest_altitude'].",60000";
33 37
                 $sql_altitude = $start_altitude;
34
-        } else $sql_altitude = '';
35
-} else $sql_altitude = '';
38
+        } else {
39
+        	$sql_altitude = '';
40
+        }
41
+        } else {
42
+	$sql_altitude = '';
43
+}
36 44
 
37 45
 //calculuation for the pagination
38 46
 if(!isset($_GET['limit']))
@@ -50,7 +58,7 @@  discard block
 block discarded – undo
50 58
                 $limit_end = $_GET['number_results'];
51 59
                 $absolute_difference = $_GET['number_results'];
52 60
         }
53
-}  else {
61
+} else {
54 62
         $limit_explode = explode(",", $_GET['limit']);
55 63
         $limit_start = $limit_explode[0];
56 64
         $limit_end = $limit_explode[1];
@@ -67,8 +75,11 @@  discard block
 block discarded – undo
67 75
 
68 76
 header("Content-type: text/csv");
69 77
 
70
-if (isset($_GET['sort'])) $sort = $_GET['sort'];
71
-else $sort = '';
78
+if (isset($_GET['sort'])) {
79
+	$sort = $_GET['sort'];
80
+} else {
81
+	$sort = '';
82
+}
72 83
 
73 84
 $q = filter_input(INPUT_GET,'q',FILTER_SANITIZE_STRING);
74 85
 $registration = filter_input(INPUT_GET,'registratrion',FILTER_SANITIZE_STRING);
Please login to merge, or discard this patch.
highlights-display.php 1 patch
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
 	$limit_start = 0;
13 13
 	$limit_end = 28;
14 14
 	$absolute_difference = 28;
15
-}  else {
15
+} else {
16 16
 	$limit_explode = explode(",", $_GET['limit']);
17 17
 	$limit_start = $limit_explode[0];
18 18
 	$limit_end = $limit_explode[1];
Please login to merge, or discard this patch.
search-kml.php 1 patch
Braces   +18 added lines, -7 removed lines patch added patch discarded remove patch
@@ -15,8 +15,12 @@  discard block
 block discarded – undo
15 15
         } else if($_GET['start_date'] == "" && $_GET['end_date'] != ""){
16 16
                 $end_date = date("Y-m-d H:i:s", strtotime("2014-04-12")).",".$_GET['end_date'].":00";
17 17
                 $sql_date = $end_date;
18
-        } else $sql_date = '';
19
-} else $sql_date = '';
18
+        } else {
19
+        	$sql_date = '';
20
+        }
21
+        } else {
22
+	$sql_date = '';
23
+}
20 24
 
21 25
 if (isset($_GET['highest_altitude'])) {
22 26
         //for altitude manipulation
@@ -30,8 +34,12 @@  discard block
 block discarded – undo
30 34
         } else if($_GET['highest_altitude'] == "" && $_GET['lowest_altitude'] != ""){
31 35
                 $start_altitude = $_GET['lowest_altitude'].",60000";
32 36
                 $sql_altitude = $start_altitude;
33
-        } else $sql_altitude = '';
34
-} else $sql_altitude = '';
37
+        } else {
38
+        	$sql_altitude = '';
39
+        }
40
+        } else {
41
+	$sql_altitude = '';
42
+}
35 43
 
36 44
 //calculuation for the pagination
37 45
 if(!isset($_GET['limit']))
@@ -49,7 +57,7 @@  discard block
 block discarded – undo
49 57
                 $limit_end = $_GET['number_results'];
50 58
                 $absolute_difference = $_GET['number_results'];
51 59
         }
52
-}  else {
60
+} else {
53 61
         $limit_explode = explode(",", $_GET['limit']);
54 62
         $limit_start = $limit_explode[0];
55 63
         $limit_end = $limit_explode[1];
@@ -67,8 +75,11 @@  discard block
 block discarded – undo
67 75
 
68 76
 header('Content-Type: text/xml');
69 77
 
70
-if (isset($_GET['sort'])) $sort = $_GET['sort'];
71
-else $sort = '';
78
+if (isset($_GET['sort'])) {
79
+	$sort = $_GET['sort'];
80
+} else {
81
+	$sort = '';
82
+}
72 83
 $q = filter_input(INPUT_GET,'q',FILTER_SANITIZE_STRING);
73 84
 $registration = filter_input(INPUT_GET,'registratrion',FILTER_SANITIZE_STRING);
74 85
 $aircraft = filter_input(INPUT_GET,'aircraft',FILTER_SANITIZE_STRING);
Please login to merge, or discard this patch.
search-rss.php 1 patch
Braces   +18 added lines, -7 removed lines patch added patch discarded remove patch
@@ -15,8 +15,12 @@  discard block
 block discarded – undo
15 15
         } else if($_GET['start_date'] == "" && $_GET['end_date'] != ""){
16 16
                 $end_date = date("Y-m-d H:i:s", strtotime("2014-04-12")).",".$_GET['end_date'].":00";
17 17
                 $sql_date = $end_date;
18
-        } else $sql_date = '';
19
-} else $sql_date = '';
18
+        } else {
19
+        	$sql_date = '';
20
+        }
21
+        } else {
22
+	$sql_date = '';
23
+}
20 24
 
21 25
 if (isset($_GET['highest_altitude'])) {
22 26
         //for altitude manipulation
@@ -30,8 +34,12 @@  discard block
 block discarded – undo
30 34
         } else if($_GET['highest_altitude'] == "" && $_GET['lowest_altitude'] != ""){
31 35
                 $start_altitude = $_GET['lowest_altitude'].",60000";
32 36
                 $sql_altitude = $start_altitude;
33
-        } else $sql_altitude = '';
34
-} else $sql_altitude = '';
37
+        } else {
38
+        	$sql_altitude = '';
39
+        }
40
+        } else {
41
+	$sql_altitude = '';
42
+}
35 43
 
36 44
 //calculuation for the pagination
37 45
 if(!isset($_GET['limit']))
@@ -49,7 +57,7 @@  discard block
 block discarded – undo
49 57
                 $limit_end = $_GET['number_results'];
50 58
                 $absolute_difference = $_GET['number_results'];
51 59
         }
52
-}  else {
60
+} else {
53 61
         $limit_explode = explode(",", $_GET['limit']);
54 62
         $limit_start = $limit_explode[0];
55 63
         $limit_end = $limit_explode[1];
@@ -70,8 +78,11 @@  discard block
 block discarded – undo
70 78
 
71 79
 $date = date("D, d M Y H:i:s T", time());
72 80
 
73
-if (isset($_GET['sort'])) $sort = $_GET['sort'];
74
-else $sort = '';
81
+if (isset($_GET['sort'])) {
82
+	$sort = $_GET['sort'];
83
+} else {
84
+	$sort = '';
85
+}
75 86
 $q = filter_input(INPUT_GET,'q',FILTER_SANITIZE_STRING);
76 87
 $registration = filter_input(INPUT_GET,'registratrion',FILTER_SANITIZE_STRING);
77 88
 $aircraft = filter_input(INPUT_GET,'aircraft',FILTER_SANITIZE_STRING);
Please login to merge, or discard this patch.
contribute.php 1 patch
Braces   +13 added lines, -2 removed lines patch added patch discarded remove patch
@@ -11,10 +11,21 @@
 block discarded – undo
11 11
     <p>You can contribute to <?php print $globalName; ?> if you have an ADS-B receiver.</p>
12 12
     <h3>You need to : </h3>
13 13
     <ul>
14
-	<li>Create an account on <a href="<?php if (isset($globalContributeLogin)) print $globalContributeLogin.'">'.$globalContributeLogin; else print 'https://login.flightairmap.fr">login.flightairmap.fr'; ?></a></li>
14
+	<li>Create an account on <a href="<?php if (isset($globalContributeLogin)) {
15
+	print $globalContributeLogin.'">'.$globalContributeLogin;
16
+} else {
17
+	print 'https://login.flightairmap.fr">login.flightairmap.fr';
18
+}
19
+?></a></li>
15 20
 	<li>Download dump1090 fork from <a href="https://github.com/Ysurac/dump1090">https://github.com/Ysurac/dump1090</a></li>
16 21
 	<li>Compile zfamup1090 with <em>make zfamup1090</em> (you need to have libcurl installed)</li>
17
-	<li>Run zfamup1090 : <em>./zfamup1090 --net-zfam-user YourUsername --net-zfam-pass YourPassword<?php if (isset($globalContributeURL)) print ' --net-zfam-addr '.$globalContributeURL; if (isset($globalContributePort)) print ' --net-zfam-port '.$globalContributePort; ?></em> (add <em>--net-bo-ipaddr ipofbeastsource --net-bo-port portofbeastsource</em> if needed, default to 127.0.0.1 and 30005)</li>
22
+	<li>Run zfamup1090 : <em>./zfamup1090 --net-zfam-user YourUsername --net-zfam-pass YourPassword<?php if (isset($globalContributeURL)) {
23
+	print ' --net-zfam-addr '.$globalContributeURL;
24
+}
25
+if (isset($globalContributePort)) {
26
+	print ' --net-zfam-port '.$globalContributePort;
27
+}
28
+?></em> (add <em>--net-bo-ipaddr ipofbeastsource --net-bo-port portofbeastsource</em> if needed, default to 127.0.0.1 and 30005)</li>
18 29
     </ul>
19 30
 </div>
20 31
 <?php
Please login to merge, or discard this patch.
tools-acars.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,9 @@
 block discarded – undo
21 21
 print '<fieldset class="form-group">';
22 22
 print '<label for="acars_message">'._("ACARS Message").'</label>';
23 23
 print '<textarea class="form-control" name="acars_message" id="acars_message" rows="5">';
24
-if ($message != '') print $message;
24
+if ($message != '') {
25
+	print $message;
26
+}
25 27
 print '</textarea>';
26 28
 print '</fieldset>';
27 29
 print '<button type="submit" class="btn btn-primary">Submit</button>';
Please login to merge, or discard this patch.