Jump to content

Need some help getting started finding locations "near me"


imanta

Recommended Posts

I am building a URL callback that returns some set of data based on the latitude and longitude of the user. I have a huge database of items that all have their own latitude and longitude and basically I just want to return the items that are within X miles of the user's. It is very simple and you see stuff like this all the time, but I am not sure where to begin. I do not have a UI to work with so I must depend entirely on back-end interfaces as I only get an HTTP request and will return structured results (XML).

 

Any direction, pointers, thoughts, etc are much appreciated. Thanks!

I did search and I have this code, but the way this is works is that I would need compare the user's info with every single item in the database and then check the result against the radius (my X). I was actually hoping to come up with a SQL based way to turn this into a SELECT statement to keep the load down. Does that make sense?

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.