Completed
Push — master ( aeed75...4249a5 )
by Yannick
31:47
created
js/map.2d.js.php 1 patch
Spacing   +14 added lines, -14 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
 if (!isset($globalOpenWeatherMapKey)) $globalOpenWeatherMapKey = '';
8 8
 // Compressed GeoJson is used if true
@@ -20,10 +20,10 @@  discard block
 block discarded – undo
20 20
 	$lastupd = $_GET['archivespeed']*$archiveupdatetime;
21 21
 	if (isset($_GET['enddate']) && $_GET['enddate'] != '') $enddate = $_GET['enddate'];
22 22
 	else $enddate = time();
23
-	setcookie("archive_begin",$begindate);
24
-	setcookie("archive_end",$enddate);
25
-	setcookie("archive_update",$lastupd);
26
-	setcookie("archive_speed",$archivespeed);
23
+	setcookie("archive_begin", $begindate);
24
+	setcookie("archive_end", $enddate);
25
+	setcookie("archive_update", $lastupd);
26
+	setcookie("archive_speed", $archivespeed);
27 27
 ?>
28 28
 document.cookie =  'archive_begin=<?php print $begindate; ?>; expires=Thu, 2 Aug 2100 20:47:11 UTC; path=/';
29 29
 document.cookie =  'archive_end=<?php print $enddate; ?>; expires=Thu, 2 Aug 2100 20:47:11 UTC; path=/';
@@ -75,16 +75,16 @@  discard block
 block discarded – undo
75 75
 <?php
76 76
 	}
77 77
 	if (isset($_GET['ident'])) {
78
-		$ident = filter_input(INPUT_GET,'ident',FILTER_SANITIZE_STRING);
78
+		$ident = filter_input(INPUT_GET, 'ident', FILTER_SANITIZE_STRING);
79 79
 	}
80 80
 	if (isset($_GET['flightaware_id'])) {
81
-		$flightaware_id = filter_input(INPUT_GET,'flightaware_id',FILTER_SANITIZE_STRING);
81
+		$flightaware_id = filter_input(INPUT_GET, 'flightaware_id', FILTER_SANITIZE_STRING);
82 82
 	}
83 83
 	if (isset($_GET['latitude'])) {
84
-		$latitude = filter_input(INPUT_GET,'latitude',FILTER_SANITIZE_STRING);
84
+		$latitude = filter_input(INPUT_GET, 'latitude', FILTER_SANITIZE_STRING);
85 85
 	}
86 86
 	if (isset($_GET['longitude'])) {
87
-		$longitude = filter_input(INPUT_GET,'longitude',FILTER_SANITIZE_STRING);
87
+		$longitude = filter_input(INPUT_GET, 'longitude', FILTER_SANITIZE_STRING);
88 88
 	}
89 89
 ?>
90 90
 
@@ -112,7 +112,7 @@  discard block
 block discarded – undo
112 112
 	} else {
113 113
 		if ((isset($globalCenterLatitude) && $globalCenterLatitude != '' && isset($globalCenterLongitude) && $globalCenterLongitude != '') || isset($_COOKIE['lastcentercoord'])) {
114 114
 			if (isset($_COOKIE['lastcentercoord'])) {
115
-				$lastcentercoord = explode(',',$_COOKIE['lastcentercoord']);
115
+				$lastcentercoord = explode(',', $_COOKIE['lastcentercoord']);
116 116
 				$viewcenterlatitude = $lastcentercoord[0];
117 117
 				$viewcenterlongitude = $lastcentercoord[1];
118 118
 				$viewzoom = $lastcentercoord[2];
@@ -133,7 +133,7 @@  discard block
 block discarded – undo
133 133
 	     || navigator.userAgent.match(/BlackBerry/i)
134 134
 	     || navigator.userAgent.match(/Windows Phone/i))
135 135
 	{
136
-		var zoom = <?php if (isset($viewzoom) && $viewzoom == $globalLiveZoom) print $viewzoom-1; elseif (isset($viewzoom)) print $viewzoom; else print '8'; ?>;
136
+		var zoom = <?php if (isset($viewzoom) && $viewzoom == $globalLiveZoom) print $viewzoom - 1; elseif (isset($viewzoom)) print $viewzoom; else print '8'; ?>;
137 137
 	} else {
138 138
 		var zoom = <?php if (isset($viewzoom)) print $viewzoom; else print '9'; ?>;
139 139
 	}
@@ -227,19 +227,19 @@  discard block
 block discarded – undo
227 227
 	map.addLayer(yandexLayer);
228 228
 <?php
229 229
 	} elseif ($MapType == 'Bing-Aerial') {
230
-		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap');
230
+		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType', 'OpenStreetMap');
231 231
 ?>
232 232
 	var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'Aerial'});
233 233
 	map.addLayer(bingLayer);
234 234
 <?php
235 235
 	} elseif ($MapType == 'Bing-Hybrid') {
236
-		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap');
236
+		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType', 'OpenStreetMap');
237 237
 ?>
238 238
 	var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'AerialWithLabels'});
239 239
 	map.addLayer(bingLayer);
240 240
 <?php
241 241
 	} elseif ($MapType == 'Bing-Road') {
242
-		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType','OpenStreetMap');
242
+		if (!isset($globalBingMapKey) || $globalBingMapKey == '') setcookie('MapType', 'OpenStreetMap');
243 243
 ?>
244 244
 	var bingLayer = new L.tileLayer.bing({bingMapsKey: '<?php print $globalBingMapKey; ?>',imagerySet: 'Road'});
245 245
 	map.addLayer(bingLayer);
Please login to merge, or discard this patch.