Query Database by distance from location

“Straightforward”? Not quite. You will need to calculate the distance between the input location and each location in your database. To do this, you will need to avail yourself of a distance calculating service such as Google Maps . See the example Google Place example to see how to get started using the API. An Internet search might turn up some other distance calculating services.