Looks like I’ll be working on an iPhone app that does the following:
– Take the current location (longitude and latitude)
– Query a private database containing coordinates + the details of that location
– Find the 5 closest recorded locations from database and display to the iPhone
In essence, what I need to make is what the locations section of the Starbucks App.
My questions:
1) In order to have the 5 locations searched, does this mean I’ll need to write a program for the server as well? If yes, what language is (typically/best) used if this is to be run on an Apache server?
2) If I wanted to display these coordinates on a map, if I am not designing a map myself (way out of my league), how would I go about creating a Google Map integration?
3) Currently I have a list of coordinates listed in a KML file. What database would you suggest I use if it is to be queried by an iPhone application, as well as an HTML page?
You can use iOS’s mapkit framework for mapping integration. Add the framework to your project, create a new viewController with the MKMapView as the main view, and assign the view controller as the MapView delegate and datasource.
For server side, just use a REST based API with JSON/XML to communicate the app and the server. The back end of the server is unimportant to the application. In terms of server-side implementation, do what you know. Could be PHP, ruby, etc.
You can create a database based on those KML files. Having the database fields separated, you can get the user’s location from the application, send that information to the server, and on your server, you would query the locations that are within a delta range from the user’s location.