@@ -12,11 +12,11 @@ discard block |
||
12 | 12 | } |
13 | 13 | |
14 | 14 | /** |
15 | - * Gets the images based on the aircraft registration |
|
16 | - * |
|
17 | - * @return Array the images list |
|
18 | - * |
|
19 | - */ |
|
15 | + * Gets the images based on the aircraft registration |
|
16 | + * |
|
17 | + * @return Array the images list |
|
18 | + * |
|
19 | + */ |
|
20 | 20 | public function getSpotterImage($registration,$aircraft_icao = '', $airline_icao = '') |
21 | 21 | { |
22 | 22 | $registration = filter_var($registration,FILTER_SANITIZE_STRING); |
@@ -36,11 +36,11 @@ discard block |
||
36 | 36 | } |
37 | 37 | |
38 | 38 | /** |
39 | - * Gets the image copyright based on the Exif data |
|
40 | - * |
|
41 | - * @return String image copyright |
|
42 | - * |
|
43 | - */ |
|
39 | + * Gets the image copyright based on the Exif data |
|
40 | + * |
|
41 | + * @return String image copyright |
|
42 | + * |
|
43 | + */ |
|
44 | 44 | public function getExifCopyright($url) { |
45 | 45 | $exif = exif_read_data($url); |
46 | 46 | $copyright = ''; |
@@ -55,11 +55,11 @@ discard block |
||
55 | 55 | } |
56 | 56 | |
57 | 57 | /** |
58 | - * Adds the images based on the aircraft registration |
|
59 | - * |
|
60 | - * @return String either success or error |
|
61 | - * |
|
62 | - */ |
|
58 | + * Adds the images based on the aircraft registration |
|
59 | + * |
|
60 | + * @return String either success or error |
|
61 | + * |
|
62 | + */ |
|
63 | 63 | public function addSpotterImage($registration,$aircraft_icao = '', $airline_icao = '') |
64 | 64 | { |
65 | 65 | global $globalDebug,$globalAircraftImageFetch; |
@@ -88,12 +88,12 @@ discard block |
||
88 | 88 | } |
89 | 89 | |
90 | 90 | /** |
91 | - * Gets the aircraft image |
|
92 | - * |
|
93 | - * @param String $aircraft_registration the registration of the aircraft |
|
94 | - * @return Array the aircraft thumbnail, orignal url and copyright |
|
95 | - * |
|
96 | - */ |
|
91 | + * Gets the aircraft image |
|
92 | + * |
|
93 | + * @param String $aircraft_registration the registration of the aircraft |
|
94 | + * @return Array the aircraft thumbnail, orignal url and copyright |
|
95 | + * |
|
96 | + */ |
|
97 | 97 | public function findAircraftImage($aircraft_registration, $aircraft_icao = '', $airline_icao = '') |
98 | 98 | { |
99 | 99 | global $globalAircraftImageSources, $globalIVAO, $globalAircraftImageCheckICAO; |
@@ -136,13 +136,13 @@ discard block |
||
136 | 136 | } |
137 | 137 | |
138 | 138 | /** |
139 | - * Gets the aircraft image from Planespotters |
|
140 | - * |
|
141 | - * @param String $aircraft_registration the registration of the aircraft |
|
142 | - * @param String $aircraft_name type of the aircraft |
|
143 | - * @return Array the aircraft thumbnail, orignal url and copyright |
|
144 | - * |
|
145 | - */ |
|
139 | + * Gets the aircraft image from Planespotters |
|
140 | + * |
|
141 | + * @param String $aircraft_registration the registration of the aircraft |
|
142 | + * @param String $aircraft_name type of the aircraft |
|
143 | + * @return Array the aircraft thumbnail, orignal url and copyright |
|
144 | + * |
|
145 | + */ |
|
146 | 146 | public function fromPlanespotters($aircraft_registration, $aircraft_name='') { |
147 | 147 | $Common = new Common(); |
148 | 148 | // If aircraft registration is only number, also check with aircraft model |
@@ -169,13 +169,13 @@ discard block |
||
169 | 169 | } |
170 | 170 | |
171 | 171 | /** |
172 | - * Gets the aircraft image from Deviantart |
|
173 | - * |
|
174 | - * @param String $aircraft_registration the registration of the aircraft |
|
175 | - * @param String $aircraft_name type of the aircraft |
|
176 | - * @return Array the aircraft thumbnail, orignal url and copyright |
|
177 | - * |
|
178 | - */ |
|
172 | + * Gets the aircraft image from Deviantart |
|
173 | + * |
|
174 | + * @param String $aircraft_registration the registration of the aircraft |
|
175 | + * @param String $aircraft_name type of the aircraft |
|
176 | + * @return Array the aircraft thumbnail, orignal url and copyright |
|
177 | + * |
|
178 | + */ |
|
179 | 179 | public function fromDeviantart($aircraft_registration, $aircraft_name='') { |
180 | 180 | $Common = new Common(); |
181 | 181 | // If aircraft registration is only number, also check with aircraft model |
@@ -203,13 +203,13 @@ discard block |
||
203 | 203 | } |
204 | 204 | |
205 | 205 | /** |
206 | - * Gets the aircraft image from JetPhotos |
|
207 | - * |
|
208 | - * @param String $aircraft_registration the registration of the aircraft |
|
209 | - * @param String $aircraft_name type of the aircraft |
|
210 | - * @return Array the aircraft thumbnail, orignal url and copyright |
|
211 | - * |
|
212 | - */ |
|
206 | + * Gets the aircraft image from JetPhotos |
|
207 | + * |
|
208 | + * @param String $aircraft_registration the registration of the aircraft |
|
209 | + * @param String $aircraft_name type of the aircraft |
|
210 | + * @return Array the aircraft thumbnail, orignal url and copyright |
|
211 | + * |
|
212 | + */ |
|
213 | 213 | public function fromJetPhotos($aircraft_registration, $aircraft_name='') { |
214 | 214 | $Common = new Common(); |
215 | 215 | $url= 'http://jetphotos.net/showphotos.php?displaymode=2®search='.$aircraft_registration; |
@@ -245,13 +245,13 @@ discard block |
||
245 | 245 | } |
246 | 246 | |
247 | 247 | /** |
248 | - * Gets the aircraft image from PlanePictures |
|
249 | - * |
|
250 | - * @param String $aircraft_registration the registration of the aircraft |
|
251 | - * @param String $aircraft_name type of the aircraft |
|
252 | - * @return Array the aircraft thumbnail, orignal url and copyright |
|
253 | - * |
|
254 | - */ |
|
248 | + * Gets the aircraft image from PlanePictures |
|
249 | + * |
|
250 | + * @param String $aircraft_registration the registration of the aircraft |
|
251 | + * @param String $aircraft_name type of the aircraft |
|
252 | + * @return Array the aircraft thumbnail, orignal url and copyright |
|
253 | + * |
|
254 | + */ |
|
255 | 255 | public function fromPlanePictures($aircraft_registration, $aircraft_name='') { |
256 | 256 | $Common = new Common(); |
257 | 257 | $url= 'http://www.planepictures.net/netsearch4.cgi?srch='.$aircraft_registration.'&stype=reg&srng=2'; |
@@ -279,13 +279,13 @@ discard block |
||
279 | 279 | } |
280 | 280 | |
281 | 281 | /** |
282 | - * Gets the aircraft image from Flickr |
|
283 | - * |
|
284 | - * @param String $aircraft_registration the registration of the aircraft |
|
285 | - * @param String $aircraft_name type of the aircraft |
|
286 | - * @return Array the aircraft thumbnail, orignal url and copyright |
|
287 | - * |
|
288 | - */ |
|
282 | + * Gets the aircraft image from Flickr |
|
283 | + * |
|
284 | + * @param String $aircraft_registration the registration of the aircraft |
|
285 | + * @param String $aircraft_name type of the aircraft |
|
286 | + * @return Array the aircraft thumbnail, orignal url and copyright |
|
287 | + * |
|
288 | + */ |
|
289 | 289 | public function fromFlickr($aircraft_registration,$aircraft_name='') { |
290 | 290 | $Common = new Common(); |
291 | 291 | if ($aircraft_name != '') $url = 'https://api.flickr.com/services/feeds/photos_public.gne?format=rss2&license=1,2,3,4,5,6,7&per_page=1&tags='.$aircraft_registration.','.urlencode($aircraft_name); |
@@ -323,13 +323,13 @@ discard block |
||
323 | 323 | } |
324 | 324 | |
325 | 325 | /** |
326 | - * Gets the aircraft image from Bing |
|
327 | - * |
|
328 | - * @param String $aircraft_registration the registration of the aircraft |
|
329 | - * @param String $aircraft_name type of the aircraft |
|
330 | - * @return Array the aircraft thumbnail, orignal url and copyright |
|
331 | - * |
|
332 | - */ |
|
326 | + * Gets the aircraft image from Bing |
|
327 | + * |
|
328 | + * @param String $aircraft_registration the registration of the aircraft |
|
329 | + * @param String $aircraft_name type of the aircraft |
|
330 | + * @return Array the aircraft thumbnail, orignal url and copyright |
|
331 | + * |
|
332 | + */ |
|
333 | 333 | public function fromBing($aircraft_registration,$aircraft_name='') { |
334 | 334 | global $globalImageBingKey; |
335 | 335 | $Common = new Common(); |
@@ -355,13 +355,13 @@ discard block |
||
355 | 355 | } |
356 | 356 | |
357 | 357 | /** |
358 | - * Gets the aircraft image from airport-data |
|
359 | - * |
|
360 | - * @param String $aircraft_registration the registration of the aircraft |
|
361 | - * @param String $aircraft_name type of the aircraft |
|
362 | - * @return Array the aircraft thumbnail, orignal url and copyright |
|
363 | - * |
|
364 | - */ |
|
358 | + * Gets the aircraft image from airport-data |
|
359 | + * |
|
360 | + * @param String $aircraft_registration the registration of the aircraft |
|
361 | + * @param String $aircraft_name type of the aircraft |
|
362 | + * @return Array the aircraft thumbnail, orignal url and copyright |
|
363 | + * |
|
364 | + */ |
|
365 | 365 | public function fromAirportData($aircraft_registration,$aircraft_name='') { |
366 | 366 | $Common = new Common(); |
367 | 367 | $url = 'http://www.airport-data.com/api/ac_thumb.json?&n=1&r='.$aircraft_registration; |
@@ -380,13 +380,13 @@ discard block |
||
380 | 380 | } |
381 | 381 | |
382 | 382 | /** |
383 | - * Gets the aircraft image from WikiMedia |
|
384 | - * |
|
385 | - * @param String $aircraft_registration the registration of the aircraft |
|
386 | - * @param String $aircraft_name type of the aircraft |
|
387 | - * @return Array the aircraft thumbnail, orignal url and copyright |
|
388 | - * |
|
389 | - */ |
|
383 | + * Gets the aircraft image from WikiMedia |
|
384 | + * |
|
385 | + * @param String $aircraft_registration the registration of the aircraft |
|
386 | + * @param String $aircraft_name type of the aircraft |
|
387 | + * @return Array the aircraft thumbnail, orignal url and copyright |
|
388 | + * |
|
389 | + */ |
|
390 | 390 | public function fromWikimedia($aircraft_registration,$aircraft_name='') { |
391 | 391 | $Common = new Common(); |
392 | 392 | if ($aircraft_name != '') $url = 'https://commons.wikimedia.org/w/api.php?action=query&list=search&format=json&srlimit=1&srnamespace=6&continue&srsearch="'.$aircraft_registration.'"%20'.urlencode($aircraft_name); |
@@ -436,13 +436,13 @@ discard block |
||
436 | 436 | } |
437 | 437 | |
438 | 438 | /** |
439 | - * Gets the aircraft image from custom url |
|
440 | - * |
|
441 | - * @param String $aircraft_registration the registration of the aircraft |
|
442 | - * @param String $aircraft_name type of the aircraft |
|
443 | - * @return Array the aircraft thumbnail, orignal url and copyright |
|
444 | - * |
|
445 | - */ |
|
439 | + * Gets the aircraft image from custom url |
|
440 | + * |
|
441 | + * @param String $aircraft_registration the registration of the aircraft |
|
442 | + * @param String $aircraft_name type of the aircraft |
|
443 | + * @return Array the aircraft thumbnail, orignal url and copyright |
|
444 | + * |
|
445 | + */ |
|
446 | 446 | public function fromCustomSource($aircraft_registration,$aircraft_name='') { |
447 | 447 | global $globalAircraftImageCustomSources, $globalDebug; |
448 | 448 | //$globalAircraftImageCustomSource[] = array('thumbnail' => '','original' => '', 'copyright' => '', 'source_website' => '', 'source' => '','exif' => true); |