Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

henktade

macrumors newbie
Original poster
Jan 30, 2009
17
0
hi,

can any one give me brief description of how to get like City names, zip codes, street names etc.. after we get the coordinates of the current location of my iPhone.

tanks
 

fishkorp

macrumors 68030
Apr 10, 2006
2,536
650
Ellicott City, MD
3.0 has a Reverse Geocoder that can do all that for you. 2.x does not, you'd have to use a 3rd party service (or provide your own) for it.
 

henktade

macrumors newbie
Original poster
Jan 30, 2009
17
0
3.0 has a Reverse Geocoder that can do all that for you. 2.x does not, you'd have to use a 3rd party service (or provide your own) for it.

so i send the coordinates to this 3rd parties? like 25.333 North , 110.0345 West

how would it be if I want to get data from maps.google.com?

tanks
 

fishkorp

macrumors 68030
Apr 10, 2006
2,536
650
Ellicott City, MD
Carefully read Google's TOS for their revers geocoder. I think you can only use their service in a free app.

However Google is providing the reverse geocoding in 3.0, with slightly modified TOS for use of the API.

If you want to use Google, I suggest you read the Google maps TOS on the web APIs, or read the TOS for 3.0 linked off the developer portal.
 

henktade

macrumors newbie
Original poster
Jan 30, 2009
17
0
Premium service

Carefully read Google's TOS for their revers geocoder. I think you can only use their service in a free app.

However Google is providing the reverse geocoding in 3.0, with slightly modified TOS for use of the API.

If you want to use Google, I suggest you read the Google maps TOS on the web APIs, or read the TOS for 3.0 linked off the developer portal.

fishkorp, tanks for the info.. as I understand now, for non-free apps u should sign for the Premium google maps api. I am wondering though if all navigation related application in Appstore use this premium service. Because I think it is quite expensive for individual programmers like me.

henk
 

fishkorp

macrumors 68030
Apr 10, 2006
2,536
650
Ellicott City, MD
Currently, I'm using my own service. I got a dump of data (free) from geonames.org. GeoNames also offers a web service, but it gets hammered a lot and your request can time out. If you make your own service you'll have to do some pretty complicated math in order to calculate the closest city/state/address based on the lat/lon coordinates. You'll need a web server and a database to offer your own service. Google isn't the only one offering reverse geocoding though, there are plenty of others (Microsoft offers it, as well as many 3rd party companies that ONLY do reverse geocoding). It's best to just do some research on the topic and figure out what works best for you and fits into your budget.

However I changed my code to use the reverse geocoder in 3.0 and it works much quicker. You can charge for apps that use the 3.0 reverse geocoder (provided by Google) as long as that isn't the only purpose of the app (like I said, read the 3.0 TOS on the topic on the dev portal). If you can wait until the summer to release your app, I'd suggest using the stuff already built into 3.0. Makes things a lot easier.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.