So, I have a google map on my site. I need the user to be able to centralize the map somewhere, and then I want on my server side to be able to sort the list of objects (each of which has the lat and long property) based on the visible part of the map at the front end. Does this make sense? Think about how Yelp.com sorts restaurants based on a map, users can zoom in / out.
So, first the list will get rid of any objects that are not in the map area, based on their lat / long properties, and then sort the remaining ones, based on which they are closest to the center of the map.
To do this, what would I need to pass to the server from the external interface, and as soon as it appears on the server, how would I do this sorting?
Scott source share