xsnowy
Joined: 07/02/2012 17:41:21
Messages: 2
Offline
|
Hi guys,
is there a way to retrieve the closest city near given latitude / longitude? I use it on my own, but the web service behaves the same.
Example: Some place in New York City. I get the following results with reverse geocoding (place+distance in km):
["Little Italy, 0.13681296377487645","Downtown Manhattan, 0.1902665853428969","SoHo, 0.3944851681490419","Lower East Side, 0.910033936135459","New York City, 1.00695437055065","Greenwich Village, 1.1061205320538845","Hillman Housing, 1.4246156975098168","East River Houses, 1.625263408842266","Vinegar Hill, 2.106118549478905","Grammercy Park, 2.1562686221616816"]
However, I'd need only New York City to be returned (the others aren't cities). Unfortunately, I cannot use admin2codes with "Little Italy" for example - it returns New York County, not New York City.
Any ideas how to get the closest city and only city near given lat/lng?
Thanks!
xsnowy
|