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) { | |
7 | $stops[$element['shortName']] = $element['name']; | |
ced309 | 8 | } |
JK | 9 | |
10 | asort($stops); | |
11 | var_export($stops); |