@@ -23,7 +23,9 @@ |
||
23 | 23 | print '<option></option>'; |
24 | 24 | $Stats = new Stats(); |
25 | 25 | $airport_names = $Stats->getAllAirportNames(); |
26 | - if (empty($airport_names)) $airport_names = $Spotter->getAllAirportNames(); |
|
26 | + if (empty($airport_names)) { |
|
27 | + $airport_names = $Spotter->getAllAirportNames(); |
|
28 | + } |
|
27 | 29 | ksort($airport_names); |
28 | 30 | foreach($airport_names as $airport_name) |
29 | 31 | { |
@@ -23,7 +23,9 @@ |
||
23 | 23 | print '<option></option>'; |
24 | 24 | $Stats = new Stats(); |
25 | 25 | $airport_names = $Stats->getAllAirportNames(); |
26 | - if (empty($airport_names)) $airport_names = $Spotter->getAllAirportNames(); |
|
26 | + if (empty($airport_names)) { |
|
27 | + $airport_names = $Spotter->getAllAirportNames(); |
|
28 | + } |
|
27 | 29 | ksort($airport_names); |
28 | 30 | foreach($airport_names as $airport_name) |
29 | 31 | { |
@@ -23,7 +23,9 @@ |
||
23 | 23 | print '<option></option>'; |
24 | 24 | $Stats = new Stats(); |
25 | 25 | $airport_names = $Stats->getAllAirportNames(); |
26 | - if (empty($airport_names)) $airport_names = $Spotter->getAllAirportNames(); |
|
26 | + if (empty($airport_names)) { |
|
27 | + $airport_names = $Spotter->getAllAirportNames(); |
|
28 | + } |
|
27 | 29 | ksort($airport_names); |
28 | 30 | foreach($airport_names as $airport_name) |
29 | 31 | { |
@@ -58,8 +58,12 @@ |
||
58 | 58 | if (!empty($spotter_array) && isset($spotter_array[0]['query_number_rows']) && $spotter_array[0]['query_number_rows'] != 0) { |
59 | 59 | include('table-output.php'); |
60 | 60 | print '<div class="pagination">'; |
61 | - if ($limit_previous_1 >= 0) print '<a href="'.$page_url.'/'.$limit_previous_1.','.$limit_previous_2.'">«'._("Previous Page").'</a>'; |
|
62 | - if ($spotter_array[0]['query_number_rows'] == $absolute_difference) print '<a href="'.$page_url.'/'.$limit_end.','.$limit_next.'">'._("Next Page").'»</a>'; |
|
61 | + if ($limit_previous_1 >= 0) { |
|
62 | + print '<a href="'.$page_url.'/'.$limit_previous_1.','.$limit_previous_2.'">«'._("Previous Page").'</a>'; |
|
63 | + } |
|
64 | + if ($spotter_array[0]['query_number_rows'] == $absolute_difference) { |
|
65 | + print '<a href="'.$page_url.'/'.$limit_end.','.$limit_next.'">'._("Next Page").'»</a>'; |
|
66 | + } |
|
63 | 67 | print '</div>'; |
64 | 68 | } |
65 | 69 | print '</div>'; |
@@ -23,7 +23,9 @@ |
||
23 | 23 | print '<option></option>'; |
24 | 24 | $Stats = new Stats(); |
25 | 25 | $airport_names = $Stats->getAllAirportNames(); |
26 | - if (empty($airport_names)) $airport_names = $Spotter->getAllAirportNames(); |
|
26 | + if (empty($airport_names)) { |
|
27 | + $airport_names = $Spotter->getAllAirportNames(); |
|
28 | + } |
|
27 | 29 | ksort($airport_names); |
28 | 30 | foreach($airport_names as $airport_name) |
29 | 31 | { |
@@ -23,7 +23,9 @@ |
||
23 | 23 | print '<option></option>'; |
24 | 24 | $Stats = new Stats(); |
25 | 25 | $airport_names = $Stats->getAllAirportNames(); |
26 | - if (empty($airport_names)) $airport_names = $Spotter->getAllAirportNames(); |
|
26 | + if (empty($airport_names)) { |
|
27 | + $airport_names = $Spotter->getAllAirportNames(); |
|
28 | + } |
|
27 | 29 | ksort($airport_names); |
28 | 30 | foreach($airport_names as $airport_name) |
29 | 31 | { |
@@ -16,7 +16,9 @@ discard block |
||
16 | 16 | print '<h1>'._("Aircrafts Types").'</h1>'; |
17 | 17 | |
18 | 18 | $aircraft_types = $Stats->getAllAircraftTypes(); |
19 | - if (empty($aircraft_types) || $aircraft_types[0]['aircraft_manufacturer'] == '') $aircraft_types = $Spotter->getAllAircraftTypes(); |
|
19 | + if (empty($aircraft_types) || $aircraft_types[0]['aircraft_manufacturer'] == '') { |
|
20 | + $aircraft_types = $Spotter->getAllAircraftTypes(); |
|
21 | + } |
|
20 | 22 | $previous = null; |
21 | 23 | print '<div class="alphabet-legend">'; |
22 | 24 | foreach($aircraft_types as $value) { |
@@ -24,10 +26,14 @@ discard block |
||
24 | 26 | $firstLetter = substr($value['aircraft_manufacturer'], 0, 1); |
25 | 27 | if($previous !== $firstLetter && $firstLetter != '(' && $firstLetter != ')') |
26 | 28 | { |
27 | - if ($previous !== null) print ' | '; |
|
29 | + if ($previous !== null) { |
|
30 | + print ' | '; |
|
31 | + } |
|
28 | 32 | print '<a href="#'.$firstLetter.'">'.$firstLetter.'</a>'; |
29 | 33 | } |
30 | - if ($firstLetter != '(' && $firstLetter != ')') $previous = $firstLetter; |
|
34 | + if ($firstLetter != '(' && $firstLetter != ')') { |
|
35 | + $previous = $firstLetter; |
|
36 | + } |
|
31 | 37 | } |
32 | 38 | print '</div>'; |
33 | 39 | $previous = null; |
@@ -38,10 +44,14 @@ discard block |
||
38 | 44 | { |
39 | 45 | if($previous !== $firstLetter && $firstLetter != '(' && $firstLetter != ')') |
40 | 46 | { |
41 | - if ($previous !== null) print '</div>'; |
|
47 | + if ($previous !== null) { |
|
48 | + print '</div>'; |
|
49 | + } |
|
42 | 50 | print '<a name="'.$firstLetter.'"></a><h4 class="alphabet-header">'.$firstLetter.'</h4><div class="alphabet">'; |
43 | 51 | } |
44 | - if ($firstLetter != '(' && $firstLetter != ')') $previous = $firstLetter; |
|
52 | + if ($firstLetter != '(' && $firstLetter != ')') { |
|
53 | + $previous = $firstLetter; |
|
54 | + } |
|
45 | 55 | print '<div class="alphabet-item">'; |
46 | 56 | print '<a href="'.$globalURL.'/aircraft/'.$value['aircraft_icao'].'">'; |
47 | 57 | if ($value['aircraft_name'] == '') { |
@@ -58,8 +58,12 @@ |
||
58 | 58 | if (!empty($spotter_array) && isset($spotter_array[0]['query_number_rows']) && $spotter_array[0]['query_number_rows'] != 0) { |
59 | 59 | include('table-output.php'); |
60 | 60 | print '<div class="pagination">'; |
61 | - if ($limit_previous_1 >= 0) print '<a href="'.$page_url.'/'.$limit_previous_1.','.$limit_previous_2.'">«'._("Previous Page").'</a>'; |
|
62 | - if ($spotter_array[0]['query_number_rows'] == $absolute_difference) print '<a href="'.$page_url.'/'.$limit_end.','.$limit_next.'">'._("Next Page").'»</a>'; |
|
61 | + if ($limit_previous_1 >= 0) { |
|
62 | + print '<a href="'.$page_url.'/'.$limit_previous_1.','.$limit_previous_2.'">«'._("Previous Page").'</a>'; |
|
63 | + } |
|
64 | + if ($spotter_array[0]['query_number_rows'] == $absolute_difference) { |
|
65 | + print '<a href="'.$page_url.'/'.$limit_end.','.$limit_next.'">'._("Next Page").'»</a>'; |
|
66 | + } |
|
63 | 67 | print '</div>'; |
64 | 68 | } |
65 | 69 | print '</div>'; |
@@ -4,7 +4,9 @@ |
||
4 | 4 | require_once('require/class.Language.php'); |
5 | 5 | $Stats = new Stats(); |
6 | 6 | $title = _("Statistics").' - '._("Most common Airline by Country"); |
7 | -if (!isset($filter_name)) $filter_name = ''; |
|
7 | +if (!isset($filter_name)) { |
|
8 | + $filter_name = ''; |
|
9 | +} |
|
8 | 10 | require_once('header.php'); |
9 | 11 | $year = filter_input(INPUT_GET,'year',FILTER_SANITIZE_NUMBER_INT); |
10 | 12 | $month = filter_input(INPUT_GET,'month',FILTER_SANITIZE_NUMBER_INT); |