Real Estate Forums
| Coding HTML, ASP, PHP, JAVA MYSQL and more. All coding questions should be asked here. |
![]() |
|
|
Thread Tools | Display Modes |
|
|||
|
I need to list a bunch of addresses of homes and property. I would like to allow the user to input their zipcode and list the matches by the closest to farthest.
This way they can enter a cental point and get all matches in a certain radius. Does ayone know of a program or method that this can be accomplished. I need to add it to an existing program, so I need something simple that wont take up too much server resources. My isp limits me to 10% cpu useage. Any help would be apreciated. |
|
|||
|
How about this? scriptsearch.com/cgi-bin/jump.cgi?ID=4509
Last edited by webmaster; 04-06-2007 at 10:51 PM. |
|
|||
|
We did something similar years ago but the details are a little vague now. From what I remember, there are some data lists that correlate the zip code to a longitude - latitude value. From there it is fairly simple math to figure out what zip codes fall within that range. I remember we might have spent an hour in Google looking for the right db . Maybe try "longitude latitude zip codes" in a search?
|
|
|||
|
the math to figure out the distance between two points on a sphere (Mother Earth) is called the haversine function. I wrote a program that uses Google API geocoder to get the lat and long, then run it through the haversine function to get the distance in miles.
here's an example... dealer locator |
![]() |
| Thread Tools | |
| Display Modes | |
|
|