Improved www.ttss.krakow.pl
Jacek Kowalski
2017-05-03 ed6c8a968b8e24ed24c2c5e97df75155393081c8
commit | author | age
ced309 1 <?php
JK 2 if(php_sapi_name() !== 'cli') die();
3
547b8d 4 $json = file_get_contents('http://www.ttss.krakow.pl/internetservice/geoserviceDispatcher/services/stopinfo/stops?left=-648000000&bottom=-324000000&right=648000000&top=324000000');
JK 5 $elements = json_decode($json, 1);
6 foreach($elements['stops'] as $element) {
e61357 7     if($element['category'] == 'other') continue;
547b8d 8     $stops[$element['shortName']] = $element['name'];
ced309 9 }
JK 10
11 asort($stops);
12 var_export($stops);