Completed
Push — master ( e14a40...cfb98e )
by Yannick
54:46 queued 27:34
created
upcoming.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -7,12 +7,12 @@  discard block
 block discarded – undo
7 7
 require_once('header.php');
8 8
 
9 9
 //calculuation for the pagination
10
-if(!isset($_GET['limit']))
10
+if (!isset($_GET['limit']))
11 11
 {
12 12
 	$limit_start = 0;
13 13
 	$limit_end = 25;
14 14
 	$absolute_difference = 25;
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];
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
 print '<div class="table column">';	
36 36
 print '<p>'._("This page shows all upcoming flights within the next 3 hours calculated using historical data, based on the number of same flights on the current day of the week &amp; current time. This does not take into account real-time delays and other factors.").'</p>';
37 37
 
38
-$sort = filter_input(INPUT_GET,'sort',FILTER_SANITIZE_STRING);
38
+$sort = filter_input(INPUT_GET, 'sort', FILTER_SANITIZE_STRING);
39 39
 if ($sort != '') {
40 40
 	$spotter_array = $Spotter->getUpcomingFlights($limit_start.",".$absolute_difference, $sort);
41 41
 } else {
Please login to merge, or discard this patch.
aircraft-detailed.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -5,16 +5,16 @@  discard block
 block discarded – undo
5 5
 require_once('require/class.Language.php');
6 6
 $Spotter = new Spotter();
7 7
 
8
-if (!isset($_GET['aircraft_type'])){
8
+if (!isset($_GET['aircraft_type'])) {
9 9
 	header('Location: '.$globalURL.'/aircraft');
10 10
 } else {
11 11
 	//calculuation for the pagination
12
-	if(!isset($_GET['limit']) || count(explode(",", $_GET['limit'])) < 2)
12
+	if (!isset($_GET['limit']) || count(explode(",", $_GET['limit'])) < 2)
13 13
 	{
14 14
 		$limit_start = 0;
15 15
 		$limit_end = 25;
16 16
 		$absolute_difference = 25;
17
-	}  else {
17
+	} else {
18 18
 		$limit_explode = explode(",", $_GET['limit']);
19 19
 		$limit_start = $limit_explode[0];
20 20
 		$limit_end = $limit_explode[1];
@@ -28,15 +28,15 @@  discard block
 block discarded – undo
28 28
 	$limit_previous_1 = $limit_start - $absolute_difference;
29 29
 	$limit_previous_2 = $limit_end - $absolute_difference;
30 30
 	
31
-	$aircraft_type = filter_input(INPUT_GET,'aircraft_type',FILTER_SANITIZE_STRING);
31
+	$aircraft_type = filter_input(INPUT_GET, 'aircraft_type', FILTER_SANITIZE_STRING);
32 32
 	$page_url = $globalURL.'/aircraft/'.$aircraft_type;
33 33
 	
34
-	$sort = htmlspecialchars(filter_input(INPUT_GET,'sort',FILTER_SANITIZE_STRING));
35
-	$spotter_array = $Spotter->getSpotterDataByAircraft($aircraft_type,$limit_start.",".$absolute_difference, $sort);
34
+	$sort = htmlspecialchars(filter_input(INPUT_GET, 'sort', FILTER_SANITIZE_STRING));
35
+	$spotter_array = $Spotter->getSpotterDataByAircraft($aircraft_type, $limit_start.",".$absolute_difference, $sort);
36 36
 	
37 37
 	if (!empty($spotter_array))
38 38
 	{
39
-		$title = sprintf(_("Detailed View for %s (%s)"),$spotter_array[0]['aircraft_name'],$spotter_array[0]['aircraft_type']);
39
+		$title = sprintf(_("Detailed View for %s (%s)"), $spotter_array[0]['aircraft_name'], $spotter_array[0]['aircraft_type']);
40 40
 		require_once('header.php');
41 41
 	    
42 42
 		print '<div class="select-item">';
@@ -46,9 +46,9 @@  discard block
 block discarded – undo
46 46
     		$Stats = new Stats();
47 47
 		$aircraft_types = $Stats->getAllAircraftTypes();
48 48
 		if (empty($aircraft_types)) $aircraft_types = $Spotter->getAllAircraftTypes();
49
-		foreach($aircraft_types as $aircrafttype)
49
+		foreach ($aircraft_types as $aircrafttype)
50 50
 		{
51
-			if($aircraft_type == $aircrafttype['aircraft_icao'])
51
+			if ($aircraft_type == $aircrafttype['aircraft_icao'])
52 52
 			{
53 53
 				print '<option value="'.$aircrafttype['aircraft_icao'].'" selected="selected">'.$aircrafttype['aircraft_manufacturer'].' '.$aircrafttype['aircraft_name'].' ('.$aircrafttype['aircraft_icao'].')</option>';
54 54
 			} else {
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
 		include('aircraft-sub-menu.php');
76 76
 	        
77 77
 		print '<div class="table column">';
78
-		print '<p>'.sprintf(_("The table below shows the detailed information of all flights from <strong>%s (%s)</strong>."),$spotter_array[0]['aircraft_name'],$spotter_array[0]['aircraft_type']).'</p>';
78
+		print '<p>'.sprintf(_("The table below shows the detailed information of all flights from <strong>%s (%s)</strong>."), $spotter_array[0]['aircraft_name'], $spotter_array[0]['aircraft_type']).'</p>';
79 79
 		  
80 80
 		include('table-output.php');
81 81
 		  
Please login to merge, or discard this patch.
incident-latest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
 
9 9
 $page_url = $globalURL.'/accident-latest';
10 10
 
11
-if(!isset($_GET['limit']))
11
+if (!isset($_GET['limit']))
12 12
 {
13 13
 	$limit_start = 0;
14 14
 	$limit_end = 25;
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
 
35 35
 print '<div class="table column">';
36 36
 print '<p>'._("The table below shows the latest Incidents.").'</p>';
37
-$spotter_array = $Accident->getAccidentData($limit_start.",".$absolute_difference,'incident');
37
+$spotter_array = $Accident->getAccidentData($limit_start.",".$absolute_difference, 'incident');
38 38
 //print_r($spotter_array);
39 39
 if (!empty($spotter_array) && $spotter_array[0]['query_number_rows'] != 0) {
40 40
 	include('table-output.php');
Please login to merge, or discard this patch.
incident-detailed.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -10,10 +10,10 @@  discard block
 block discarded – undo
10 10
 {
11 11
 	$date = date('Y-m-d');
12 12
 } else {
13
-	$date = filter_input(INPUT_GET,'date',FILTER_SANITIZE_STRING);
13
+	$date = filter_input(INPUT_GET, 'date', FILTER_SANITIZE_STRING);
14 14
 }
15 15
 
16
-if(!isset($_GET['limit']))
16
+if (!isset($_GET['limit']))
17 17
 {
18 18
 	$limit_start = 0;
19 19
 	$limit_end = 25;
@@ -48,12 +48,12 @@  discard block
 block discarded – undo
48 48
 print '<br />';
49 49
 
50 50
 print '<div class="info column">';
51
-print '<h1>'.sprintf(_("Incidents from %s"),date("l F j, Y",strtotime($date))).'</h1>';
51
+print '<h1>'.sprintf(_("Incidents from %s"), date("l F j, Y", strtotime($date))).'</h1>';
52 52
 print '</div>';
53 53
 
54 54
 print '<div class="table column">';
55
-print '<p>'.sprintf(_("The table below shows the Incidents on <strong>%s</strong>."),date("l M j, Y",strtotime($date))).'</p>';
56
-$spotter_array = $Accident->getAccidentData($limit_start.",".$absolute_difference,'incident',$date);
55
+print '<p>'.sprintf(_("The table below shows the Incidents on <strong>%s</strong>."), date("l M j, Y", strtotime($date))).'</p>';
56
+$spotter_array = $Accident->getAccidentData($limit_start.",".$absolute_difference, 'incident', $date);
57 57
 //print_r($spotter_array);
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');
Please login to merge, or discard this patch.
js/map.js.php 1 patch
Spacing   +30 added lines, -30 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@  discard block
 block discarded – undo
2 2
 require_once('../require/settings.php');
3 3
 require_once('../require/class.Language.php'); 
4 4
 
5
-setcookie("MapFormat",'2d');
5
+setcookie("MapFormat", '2d');
6 6
 
7 7
 // Compressed GeoJson is used if true
8 8
 if (!isset($globalJsonCompress)) $compress = true;
@@ -18,10 +18,10 @@  discard block
 block discarded – undo
18 18
 	$lastupd = $_GET['archivespeed']*$archiveupdatetime;
19 19
 	if (isset($_GET['enddate']) && $_GET['enddate'] != '') $enddate = $_GET['enddate'];
20 20
 	else $enddate = time();
21
-	setcookie("archive_begin",$begindate);
22
-	setcookie("archive_end",$enddate);
23
-	setcookie("archive_update",$lastupd);
24
-	setcookie("archive_speed",$archivespeed);
21
+	setcookie("archive_begin", $begindate);
22
+	setcookie("archive_end", $enddate);
23
+	setcookie("archive_update", $lastupd);
24
+	setcookie("archive_speed", $archivespeed);
25 25
 ?>
26 26
 document.cookie =  'archive_begin=<?php print $begindate; ?>; expires=Thu, 2 Aug 2100 20:47:11 UTC; path=/';
27 27
 document.cookie =  'archive_end=<?php print $enddate; ?>; expires=Thu, 2 Aug 2100 20:47:11 UTC; path=/';
@@ -92,16 +92,16 @@  discard block
 block discarded – undo
92 92
 <?php
93 93
 	}
94 94
 	if (isset($_GET['ident'])) {
95
-		$ident = filter_input(INPUT_GET,'ident',FILTER_SANITIZE_STRING);
95
+		$ident = filter_input(INPUT_GET, 'ident', FILTER_SANITIZE_STRING);
96 96
 	}
97 97
 	if (isset($_GET['flightaware_id'])) {
98
-		$flightaware_id = filter_input(INPUT_GET,'flightaware_id',FILTER_SANITIZE_STRING);
98
+		$flightaware_id = filter_input(INPUT_GET, 'flightaware_id', FILTER_SANITIZE_STRING);
99 99
 	}
100 100
 	if (isset($_GET['latitude'])) {
101
-		$latitude = filter_input(INPUT_GET,'latitude',FILTER_SANITIZE_STRING);
101
+		$latitude = filter_input(INPUT_GET, 'latitude', FILTER_SANITIZE_STRING);
102 102
 	}
103 103
 	if (isset($_GET['longitude'])) {
104
-		$longitude = filter_input(INPUT_GET,'longitude',FILTER_SANITIZE_STRING);
104
+		$longitude = filter_input(INPUT_GET, 'longitude', FILTER_SANITIZE_STRING);
105 105
 	}
106 106
 ?>
107 107
 
@@ -136,7 +136,7 @@  discard block
 block discarded – undo
136 136
 	     || navigator.userAgent.match(/BlackBerry/i)
137 137
 	     || navigator.userAgent.match(/Windows Phone/i))
138 138
 	{
139
-		var zoom = <?php if (isset($globalLiveZoom)) print $globalLiveZoom-1; else print '8'; ?>;
139
+		var zoom = <?php if (isset($globalLiveZoom)) print $globalLiveZoom - 1; else print '8'; ?>;
140 140
 	} else {
141 141
 		var zoom = <?php if (isset($globalLiveZoom)) print $globalLiveZoom; else print '9'; ?>;
142 142
 	}
@@ -230,19 +230,19 @@  discard block
 block discarded – undo
230 230
 	map.addLayer(yandexLayer);
231 231
 <?php
232 232
 	} elseif ($MapType == 'Bing-Aerial') {
233
-		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap');
233
+		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType', 'OpenStreetMap');
234 234
 ?>
235 235
 	var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'Aerial'});
236 236
 	map.addLayer(bingLayer);
237 237
 <?php
238 238
 	} elseif ($MapType == 'Bing-Hybrid') {
239
-		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap');
239
+		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType', 'OpenStreetMap');
240 240
 ?>
241 241
 	var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'AerialWithLabels'});
242 242
 	map.addLayer(bingLayer);
243 243
 <?php
244 244
 	} elseif ($MapType == 'Bing-Road') {
245
-		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap');
245
+		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType', 'OpenStreetMap');
246 246
 ?>
247 247
 	var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'Road'});
248 248
 	map.addLayer(bingLayer);
@@ -534,10 +534,10 @@  discard block
 block discarded – undo
534 534
 	};
535 535
 	archive.update = function (props) {
536 536
 		if (typeof props != 'undefined') {
537
-			//this._div.innerHTML = '<h4><?php echo str_replace("'","\'",_("Archive Date & Time")); ?></h4>' +  '<b>' + props.archive_date + ' UTC </b>' + '<br/><i class="fa fa-fast-backward" aria-hidden="true"></i> <i class="fa fa-backward" aria-hidden="true"></i>  <a href="#" onClick="archivePause();"><i class="fa fa-pause" aria-hidden="true"></i></a> <a href="#" onClick="archivePlay();"><i class="fa fa-play" aria-hidden="true"></i></a>  <i class="fa fa-forward" aria-hidden="true"></i> <i class="fa fa-fast-forward" aria-hidden="true"></i>';
538
-			this._div.innerHTML = '<h4><?php echo str_replace("'","\'",_("Archive Date & Time")); ?></h4>' +  '<b>' + props.archive_date + ' UTC </b>' + '<br/><a href="#" onClick="archivePause();"><i class="fa fa-pause" aria-hidden="true"></i></a> <a href="#" onClick="archivePlay();"><i class="fa fa-play" aria-hidden="true"></i></a>';
537
+			//this._div.innerHTML = '<h4><?php echo str_replace("'", "\'", _("Archive Date & Time")); ?></h4>' +  '<b>' + props.archive_date + ' UTC </b>' + '<br/><i class="fa fa-fast-backward" aria-hidden="true"></i> <i class="fa fa-backward" aria-hidden="true"></i>  <a href="#" onClick="archivePause();"><i class="fa fa-pause" aria-hidden="true"></i></a> <a href="#" onClick="archivePlay();"><i class="fa fa-play" aria-hidden="true"></i></a>  <i class="fa fa-forward" aria-hidden="true"></i> <i class="fa fa-fast-forward" aria-hidden="true"></i>';
538
+			this._div.innerHTML = '<h4><?php echo str_replace("'", "\'", _("Archive Date & Time")); ?></h4>' +  '<b>' + props.archive_date + ' UTC </b>' + '<br/><a href="#" onClick="archivePause();"><i class="fa fa-pause" aria-hidden="true"></i></a> <a href="#" onClick="archivePlay();"><i class="fa fa-play" aria-hidden="true"></i></a>';
539 539
 		} else {
540
-			this._div.innerHTML = '<h4><?php echo str_replace("'","\'",_("Archive Date & Time")); ?></h4>' +  '<b><i class="fa fa-spinner fa-pulse fa-2x fa-fw margin-bottom"></i></b>';
540
+			this._div.innerHTML = '<h4><?php echo str_replace("'", "\'", _("Archive Date & Time")); ?></h4>' +  '<b><i class="fa fa-spinner fa-pulse fa-2x fa-fw margin-bottom"></i></b>';
541 541
 		}
542 542
 
543 543
 	};
@@ -737,7 +737,7 @@  discard block
 block discarded – undo
737 737
 <?php
738 738
 		} else {
739 739
 ?>
740
-		    var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000);
740
+		    var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000);
741 741
 		    return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{
742 742
 <?php
743 743
 		}
@@ -753,7 +753,7 @@  discard block
 block discarded – undo
753 753
 			    /*
754 754
 			    shadowUrl: iconURLShadowpath,
755 755
 			    shadowSize: [<?php print $globalAircraftSize; ?>, <?php print $globalAircraftSize; ?>],
756
-			    shadowAnchor: [<?php print ($globalAircraftSize/2)+1; ?>, <?php print $globalAircraftSize; ?>]
756
+			    shadowAnchor: [<?php print ($globalAircraftSize/2) + 1; ?>, <?php print $globalAircraftSize; ?>]
757 757
 			    */
758 758
 			})
759 759
 		    })
@@ -786,7 +786,7 @@  discard block
 block discarded – undo
786 786
 <?php
787 787
 		} else {
788 788
 ?>
789
-			    var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000);
789
+			    var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000);
790 790
 			    return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{
791 791
 <?php
792 792
 		}
@@ -834,7 +834,7 @@  discard block
 block discarded – undo
834 834
 <?php
835 835
 		} else {
836 836
 ?>
837
-			    var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000+20000; ?>+feature.properties.sqt*1000);
837
+			    var movingtime = Math.round(<?php if (isset($archiveupdatetime)) print $archiveupdatetime*1000; else print $globalMapRefresh*1000 + 20000; ?>+feature.properties.sqt*1000);
838 838
 			    return new L.Marker.movingMarker([latLng, feature.properties.nextlatlon],[movingtime],{
839 839
 <?php
840 840
 		}
@@ -1460,23 +1460,23 @@  discard block
 block discarded – undo
1460 1460
 	    airs.push(air.value);
1461 1461
 	}
1462 1462
     }
1463
-    document.cookie =  'filter_Airlines='+airs.join()+'; expires=<?php print date("D, j M Y G:i:s T",mktime(0, 0, 0, date("m")  , date("d")+1, date("Y"))); ?>; path=/'
1463
+    document.cookie =  'filter_Airlines='+airs.join()+'; expires=<?php print date("D, j M Y G:i:s T", mktime(0, 0, 0, date("m"), date("d") + 1, date("Y"))); ?>; path=/'
1464 1464
 }
1465 1465
 function airlinestype(selectObj) {
1466 1466
     var idx = selectObj.selectedIndex;
1467 1467
     var airtype = selectObj.options[idx].value;
1468
-    document.cookie =  'filter_airlinestype='+airtype+'; expires=<?php print date("D, j M Y G:i:s T",mktime(0, 0, 0, date("m")  , date("d")+1, date("Y"))); ?>; path=/'
1468
+    document.cookie =  'filter_airlinestype='+airtype+'; expires=<?php print date("D, j M Y G:i:s T", mktime(0, 0, 0, date("m"), date("d") + 1, date("Y"))); ?>; path=/'
1469 1469
 }
1470 1470
 function alliance(selectObj) {
1471 1471
     var idx = selectObj.selectedIndex;
1472 1472
     var alliance = selectObj.options[idx].value;
1473
-    document.cookie =  'filter_alliance='+alliance+'; expires=<?php print date("D, j M Y G:i:s T",mktime(0, 0, 0, date("m")  , date("d")+1, date("Y"))); ?>; path=/'
1473
+    document.cookie =  'filter_alliance='+alliance+'; expires=<?php print date("D, j M Y G:i:s T", mktime(0, 0, 0, date("m"), date("d") + 1, date("Y"))); ?>; path=/'
1474 1474
 }
1475 1475
 
1476 1476
 function identfilter() {
1477 1477
     var ident = $('#identfilter').val();
1478 1478
     console.log('Filter with '+ident);
1479
-    document.cookie =  'filter_ident='+ident+'; expires=<?php print date("D, j M Y G:i:s T",mktime(0, 0, 0, date("m")  , date("d")+2, date("Y"))); ?>; path=/'
1479
+    document.cookie =  'filter_ident='+ident+'; expires=<?php print date("D, j M Y G:i:s T", mktime(0, 0, 0, date("m"), date("d") + 2, date("Y"))); ?>; path=/'
1480 1480
 }
1481 1481
 function removefilters() {
1482 1482
     // Get an array of all cookie names (the regex matches what we don't want)
@@ -1498,7 +1498,7 @@  discard block
 block discarded – undo
1498 1498
 	}
1499 1499
     }
1500 1500
     //document.cookie =  'Sources='+sources.join()+'; expires=Thu, 2 Aug 2100 20:47:11 UTC; path=/'
1501
-    document.cookie =  'filter_Sources='+sources.join()+'; expires=<?php print date("D, j M Y G:i:s T",mktime(0, 0, 0, date("m")  , date("d")+1, date("Y"))); ?>; path=/'
1501
+    document.cookie =  'filter_Sources='+sources.join()+'; expires=<?php print date("D, j M Y G:i:s T", mktime(0, 0, 0, date("m"), date("d") + 1, date("Y"))); ?>; path=/'
1502 1502
 }
1503 1503
 
1504 1504
 function show3D() {
@@ -1521,23 +1521,23 @@  discard block
 block discarded – undo
1521 1521
 
1522 1522
 function clickVATSIM(cb) {
1523 1523
     //document.cookie =  'ShowVATSIM='+cb.checked+'; expires=Thu, 2 Aug 2100 20:47:11 UTC; path=/'
1524
-    document.cookie =  'filter_ShowVATSIM='+cb.checked+'; expires=<?php print date("D, j M Y G:i:s T",mktime(0, 0, 0, date("m")  , date("d")+2, date("Y"))); ?>; path=/'
1524
+    document.cookie =  'filter_ShowVATSIM='+cb.checked+'; expires=<?php print date("D, j M Y G:i:s T", mktime(0, 0, 0, date("m"), date("d") + 2, date("Y"))); ?>; path=/'
1525 1525
 }
1526 1526
 function clickIVAO(cb) {
1527 1527
     //document.cookie =  'ShowIVAO='+cb.checked+'; expires=Thu, 2 Aug 2100 20:47:11 UTC; path=/'
1528
-    document.cookie =  'filter_ShowIVAO='+cb.checked+'; expires=<?php print date("D, j M Y G:i:s T",mktime(0, 0, 0, date("m")  , date("d")+2, date("Y"))); ?>; path=/'
1528
+    document.cookie =  'filter_ShowIVAO='+cb.checked+'; expires=<?php print date("D, j M Y G:i:s T", mktime(0, 0, 0, date("m"), date("d") + 2, date("Y"))); ?>; path=/'
1529 1529
 }
1530 1530
 function clickphpVMS(cb) {
1531 1531
     //document.cookie =  'ShowVMS='+cb.checked+'; expires=Thu, 2 Aug 2100 20:47:11 UTC; path=/'
1532
-    document.cookie =  'filter_ShowVMS='+cb.checked+'; expires=<?php print date("D, j M Y G:i:s T",mktime(0, 0, 0, date("m")  , date("d")+2, date("Y"))); ?>; path=/'
1532
+    document.cookie =  'filter_ShowVMS='+cb.checked+'; expires=<?php print date("D, j M Y G:i:s T", mktime(0, 0, 0, date("m"), date("d") + 2, date("Y"))); ?>; path=/'
1533 1533
 }
1534 1534
 function clickSBS1(cb) {
1535 1535
     //document.cookie =  'ShowSBS1='+cb.checked+'; expires=Thu, 2 Aug 2100 20:47:11 UTC; path=/'
1536
-    document.cookie =  'filter_ShowSBS1='+cb.checked+'; expires=<?php print date("D, j M Y G:i:s T",mktime(0, 0, 0, date("m")  , date("d")+2, date("Y"))); ?>; path=/'
1536
+    document.cookie =  'filter_ShowSBS1='+cb.checked+'; expires=<?php print date("D, j M Y G:i:s T", mktime(0, 0, 0, date("m"), date("d") + 2, date("Y"))); ?>; path=/'
1537 1537
 }
1538 1538
 function clickAPRS(cb) {
1539 1539
     //document.cookie =  'ShowAPRS='+cb.checked+'; expires=Thu, 2 Aug 2100 20:47:11 UTC; path=/'
1540
-    document.cookie =  'filter_ShowAPRS='+cb.checked+'; expires=<?php print date("D, j M Y G:i:s T",mktime(0, 0, 0, date("m")  , date("d")+2, date("Y"))); ?>; path=/'
1540
+    document.cookie =  'filter_ShowAPRS='+cb.checked+'; expires=<?php print date("D, j M Y G:i:s T", mktime(0, 0, 0, date("m"), date("d") + 2, date("Y"))); ?>; path=/'
1541 1541
 }
1542 1542
 function clickFlightPopup(cb) {
1543 1543
     document.cookie =  'flightpopup='+cb.checked+'; expires=Thu, 2 Aug 2100 20:47:11 UTC; path=/'
Please login to merge, or discard this patch.
date-statistics-airline.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -4,14 +4,14 @@  discard block
 block discarded – undo
4 4
 require_once('require/class.Language.php');
5 5
 
6 6
 $Spotter = new Spotter();
7
-$sort = filter_input(INPUT_GET,'sort',FILTER_SANITIZE_STRING);
8
-$date = filter_input(INPUT_GET,'date',FILTER_SANITIZE_STRING);
9
-if (isset($_GET['date'])) $spotter_array = $Spotter->getSpotterDataByDate($date,"0,1", $sort);
7
+$sort = filter_input(INPUT_GET, 'sort', FILTER_SANITIZE_STRING);
8
+$date = filter_input(INPUT_GET, 'date', FILTER_SANITIZE_STRING);
9
+if (isset($_GET['date'])) $spotter_array = $Spotter->getSpotterDataByDate($date, "0,1", $sort);
10 10
 else $spotter_array = '';
11 11
 
12 12
 if (!empty($spotter_array))
13 13
 {
14
-	$title = sprintf(_("Most Common Airlines on %s"),date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601'])));
14
+	$title = sprintf(_("Most Common Airlines on %s"), date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601'])));
15 15
 
16 16
 	require_once('header.php');
17 17
 	print '<div class="select-item">';
@@ -29,13 +29,13 @@  discard block
 block discarded – undo
29 29
 	print '<script type="text/javascript">$(function () { $("#datepicker").datetimepicker({ format: "YYYY-MM-DD", defaultDate: "'.$date.'" }); }); </script>';
30 30
 	print '<br />';
31 31
 	print '<div class="info column">';
32
-	print '<h1>'.sprintf(_("Flights from %s"),date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</h1>';
32
+	print '<h1>'.sprintf(_("Flights from %s"), date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</h1>';
33 33
 	print '</div>';
34 34
 
35 35
 	include('date-sub-menu.php');
36 36
 	print '<div class="column">';
37 37
 	print '<h2>'._("Most Common Airlines").'</h2>';
38
-	print '<p>'.sprintf(_("The statistic below shows the most common airlines of flights on <strong>%s</strong>."),date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</p>';
38
+	print '<p>'.sprintf(_("The statistic below shows the most common airlines of flights on <strong>%s</strong>."), date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</p>';
39 39
 
40 40
 	$airline_array = $Spotter->countAllAirlinesByDate($date);
41 41
 	if (!empty($airline_array))
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
 		print '</thead>';
53 53
 		print '<tbody>';
54 54
 		$i = 1;
55
-		foreach($airline_array as $airline_item)
55
+		foreach ($airline_array as $airline_item)
56 56
 		{
57 57
 			print '<tr>';
58 58
 			print '<td><strong>'.$i.'</strong></td>';
Please login to merge, or discard this patch.
date-statistics-manufacturer.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -3,13 +3,13 @@  discard block
 block discarded – undo
3 3
 require_once('require/class.Spotter.php');
4 4
 require_once('require/class.Language.php');
5 5
 $Spotter = new Spotter();
6
-$sort = filter_input(INPUT_GET,'sort',FILTER_SANITIZE_STRING);
7
-$date = filter_input(INPUT_GET,'date',FILTER_SANITIZE_STRING);
8
-$spotter_array = $Spotter->getSpotterDataByDate($date,"0,1", $sort);
6
+$sort = filter_input(INPUT_GET, 'sort', FILTER_SANITIZE_STRING);
7
+$date = filter_input(INPUT_GET, 'date', FILTER_SANITIZE_STRING);
8
+$spotter_array = $Spotter->getSpotterDataByDate($date, "0,1", $sort);
9 9
 
10 10
 if (!empty($spotter_array))
11 11
 {
12
-	$title = sprintf(_("Most Common Aircraft Manufacturer on %s"),date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601'])));
12
+	$title = sprintf(_("Most Common Aircraft Manufacturer on %s"), date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601'])));
13 13
 
14 14
 	require_once('header.php');
15 15
 	print '<div class="select-item">';
@@ -27,13 +27,13 @@  discard block
 block discarded – undo
27 27
 	print '<script type="text/javascript">$(function () { $("#datepicker").datetimepicker({ format: "YYYY-MM-DD", defaultDate: "'.$date.'" }); }); </script>';
28 28
 	print '<br />';
29 29
 	print '<div class="info column">';
30
-	print '<h1>'.sprintf(_("Flights from %s"),date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</h1>';
30
+	print '<h1>'.sprintf(_("Flights from %s"), date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</h1>';
31 31
 	print '</div>';
32 32
 
33 33
 	include('date-sub-menu.php');
34 34
 	print '<div class="column">';
35 35
 	print '<h2>'._("Most Common Aircraft Manufacturer").'</h2>';
36
-	print '<p>'.sprintf(_("The statistic below shows the most common Aircraft Manufacturer of flights on <strong>%s</strong>."),date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</p>';
36
+	print '<p>'.sprintf(_("The statistic below shows the most common Aircraft Manufacturer of flights on <strong>%s</strong>."), date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</p>';
37 37
 
38 38
 	$manufacturers_array = $Spotter->countAllAircraftManufacturerByDate($date);
39 39
 	if (!empty($manufacturers_array))
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
 		print '</thead>';
49 49
 		print '<tbody>';
50 50
 		$i = 1;
51
-		foreach($manufacturers_array as $manufacturer_item)
51
+		foreach ($manufacturers_array as $manufacturer_item)
52 52
 		{
53 53
 			print '<tr>';
54 54
 			print '<td><strong>'.$i.'</strong></td>';
Please login to merge, or discard this patch.
date-statistics-registration.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -3,9 +3,9 @@  discard block
 block discarded – undo
3 3
 require_once('require/class.Spotter.php');
4 4
 require_once('require/class.Language.php');
5 5
 $Spotter = new Spotter();
6
-$sort = filter_input(INPUT_GET,'sort',FILTER_SANITIZE_STRING);
7
-$date = filter_input(INPUT_GET,'date',FILTER_SANITIZE_STRING);
8
-$spotter_array = $Spotter->getSpotterDataByDate($date,"0,1", $sort);
6
+$sort = filter_input(INPUT_GET, 'sort', FILTER_SANITIZE_STRING);
7
+$date = filter_input(INPUT_GET, 'date', FILTER_SANITIZE_STRING);
8
+$spotter_array = $Spotter->getSpotterDataByDate($date, "0,1", $sort);
9 9
 
10 10
 if (!empty($spotter_array))
11 11
 {
@@ -27,13 +27,13 @@  discard block
 block discarded – undo
27 27
 	print '<script type="text/javascript">$(function () { $("#datepicker").datetimepicker({ format: "YYYY-MM-DD", defaultDate: "'.$date.'" }); }); </script>';
28 28
 	print '<br />';
29 29
 	print '<div class="info column">';
30
-	print '<h1>'.sprintf(_("Flights from %s"),date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</h1>';
30
+	print '<h1>'.sprintf(_("Flights from %s"), date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</h1>';
31 31
 	print '</div>';
32 32
 
33 33
 	include('date-sub-menu.php');
34 34
 	print '<div class="column">';
35 35
 	print '<h2>'._("Most Common Aircraft by Registration").'</h2>';
36
-	print '<p>'.sprintf(_("The statistic below shows the most common aircraft by registration of flights on <strong>%s</strong>."),date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</p>';
36
+	print '<p>'.sprintf(_("The statistic below shows the most common aircraft by registration of flights on <strong>%s</strong>."), date("l F j, Y", strtotime($spotter_array[0]['date_iso_8601']))).'</p>';
37 37
 
38 38
 	$aircraft_array = $Spotter->countAllAircraftRegistrationByDate($date);
39 39
 	if (!empty($aircraft_array))
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
 		print '</thead>';
51 51
 		print '<tbody>';
52 52
 		$i = 1;
53
-		foreach($aircraft_array as $aircraft_item)
53
+		foreach ($aircraft_array as $aircraft_item)
54 54
 		{
55 55
 			print '<tr>';
56 56
 			print '<td><strong>'.$i.'</strong></td>';
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
 				if (isset($aircraft_item['aircraft_type'])) {
61 61
 					print '<a href="'.$globalURL.'/registration/'.$aircraft_item['registration'].'"><img src="'.$aircraft_item['image_thumbnail'].'" class="img-rounded" data-toggle="popover" title="'.$aircraft_item['registration'].' - '.$aircraft_item['aircraft_icao'].' - '.$aircraft_item['airline_name'].'" alt="'.$aircraft_item['registration'].' - '.$aircraft_item['aircraft_type'].' - '.$aircraft_item['airline_name'].'" data-content="'._("Registration:").' '.$aircraft_item['registration'].'<br />'._("Aircraft:").' '.$aircraft_item['aircraft_name'].' ('.$aircraft_item['aircraft_icao'].')<br />'._("Airline:").' '.$aircraft_item['airline_name'].'" data-html="true" width="100px" /></a>';
62 62
 				} else {
63
-					print '<a href="'.$globalURL.'/registration/'.$aircraft_item['registration'].'"><img src="'.$aircraft_item['image_thumbnail'].'" class="img-rounded" data-toggle="popover" title="'.$aircraft_item['registration'].' - '.$aircraft_item['aircraft_icao'].' - '.$aircraft_item['airline_name'].'" alt="'.$aircraft_item['registration'].' - '.$aircraft_item['airline_name'].'" data-content="'._("Registration:").' '.$aircraft_item['registration'].'<br />'._("Aircraft:").' '.$aircraft_item['aircraft_name'].' ('.$aircraft_item['aircraft_icao'].')<br />'._("Airline:");' '.$aircraft_item['airline_name'].'" data-html="true" width="100px" /></a>';
63
+					print '<a href="'.$globalURL.'/registration/'.$aircraft_item['registration'].'"><img src="'.$aircraft_item['image_thumbnail'].'" class="img-rounded" data-toggle="popover" title="'.$aircraft_item['registration'].' - '.$aircraft_item['aircraft_icao'].' - '.$aircraft_item['airline_name'].'" alt="'.$aircraft_item['registration'].' - '.$aircraft_item['airline_name'].'" data-content="'._("Registration:").' '.$aircraft_item['registration'].'<br />'._("Aircraft:").' '.$aircraft_item['aircraft_name'].' ('.$aircraft_item['aircraft_icao'].')<br />'._("Airline:"); ' '.$aircraft_item['airline_name'].'" data-html="true" width="100px" /></a>';
64 64
 				}
65 65
 				print '</td>';
66 66
 			} else {
Please login to merge, or discard this patch.
highlights-table.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -7,12 +7,12 @@  discard block
 block discarded – undo
7 7
 require_once('header.php');
8 8
 
9 9
 //calculuation for the pagination
10
-if(!isset($_GET['limit']) || $_GET['limit'] == "")
10
+if (!isset($_GET['limit']) || $_GET['limit'] == "")
11 11
 {
12 12
 	$limit_start = 0;
13 13
 	$limit_end = 25;
14 14
 	$absolute_difference = 25;
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];
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
 print '<div class="table column">';	
40 40
 print '<p>'._("The table below shows the detailed information of all custom selected flights who have special aspects to it, such as unique liveries, destinations etc.").'</p>';
41 41
 
42
-$sort = filter_input(INPUT_GET,'sort',FILTER_SANITIZE_STRING);
42
+$sort = filter_input(INPUT_GET, 'sort', FILTER_SANITIZE_STRING);
43 43
 if ($sort != '') {
44 44
 	$spotter_array = $Spotter->getSpotterDataByHighlight($limit_start.",".$absolute_difference, $sort);
45 45
 } else {
Please login to merge, or discard this patch.