I am using the Place Searches from the Google Places API and wanted to know how the JSON results are returned/ordered.
E.g. are the list of places returned in a random order within the results array; or are they returned in order of nearest distance to the specified location i.e. with the first result in the results array being the nearest place to the specified location?
I am using the Place Searches from the Google Places API and wanted to
Share
This is determined by the
rankbyparameter, which lets you choose either prominence (best search result match) or distance.More info: https://developers.google.com/maps/documentation/places/#PlaceSearchRequests