Foren / Craftwork / Server-side / Radius search

zip code radius

alphaphoenix
#1 16. August 2009, 01:53
I am looking to provide a radius search that allows a member to see what other members are in a specific area surrounding them. I installed the google map api but have not been able to figure out the zip code search for the radius.
GHengeveld
#2 16. August 2009, 04:38
I think this is not the right place for such a question. You would be better off asking it in the ]
google maps api group. I doubt there are many (if any) members here with experience in the Google maps api.
Kilandor
#3 16. August 2009, 13:42
I do I do, well sorta to a point. It just involves the normal geoip/geocode api and coomparing the lat/lon against the stored.

Added 5 minutes later:

While this is for a store locator, this is the exact basic of what you want.

http://code.google.com/apis/maps/articles/phpsqlsearch.html

It has everything you need to do what you want.

Dieser Beitrag wurde von Kilandor (am 16. August 2009, 13:48, vor 14 Jahre) bearbeitet
alphaphoenix
#4 18. August 2009, 01:43
Thank you this helped me out.

Everything is setup but my only issue is I need to place another insert into sql command to push the location data from the user profile to a second table "markers" to populate the radius search location database.

Is there an easier way?
Kilandor
#5 18. August 2009, 02:27
Why not just query the users Table?
alphaphoenix
#6 18. August 2009, 09:23
I tried this by modifying the usermap plugin but I am getting no search results. Your idea sounds good but shouldnt I first use the geocoder in the usermap plugin? when I do that it stores that lat log in its table with adress and name. The users table only has adress which need to be converted before I run the actualy query.