savagenoob
savagenoob

Reputation: 413

IPhone Geocoding

There is absolutely no tutorials on geocoding on the iphone. Only reverse geocoding. I have an address, want to convert to coordinates, then display a streetview of that address. How can this be accomplished...

EDIT

The below answer pretty much echos what I found online, but I know this can be accomplished using Googles JSON geocoding. I am working on this now, will update post when I figure out how to pull out the coordinates.

"http://maps.google.com/maps/geo?q="+ address+"&key="+apiKey+"&sensor=false&output=json"

Upvotes: 0

Views: 318

Answers (1)

Mike K
Mike K

Reputation: 2227

built in forward geocoding is new to iOS5. look at CLGeocoder, which includes methods like geocodeAddressString:completionHandler:. if you want to support pre-iOS5 then you'll have to use another service, e.g. google's. i haven't used it myself, but a quick search turned up: https://github.com/mjisrawi/iOS-Geocoding-Services which may be of use.

Upvotes: 2

Related Questions