code-for-chapel-hill / CrashModel

View current project at https://code-for-chapel-hill.github.io/CrashModel/
MIT License
4 stars 6 forks source link

Write a function to convert lat and long into street name. #17

Closed bimbashrestha closed 5 years ago

bimbashrestha commented 5 years ago

It looks like you can do this by calling this open street map web api:

$.get('https://nominatim.openstreetmap.org/reverse?format=jsonv2&lat=47.217954&lon=-1.552918', function(data){ console.log(data.address.road); });

create and test a function in https://github.com/code-for-chapel-hill/CrashModel/blob/master/js/geo_functions.js

(next task will be to convert coordinates on the sidebar to road names)

bimbashrestha commented 5 years ago

Resolving this for now with ea0b816d8eca4d15fbfbc03b8bd2dccc5a0ad437

May have to change this later on