Click to See Complete Forum and Search --> : Does anyone know how to....


G.factor
09-19-2007, 02:21 AM
:confused: Im developing a website that will allow people to post and sell their stuff..

my question is. how can a user when he search by postal code distance lets say by 5 or 10 kms, it gives him all the listings within this area postal codes..

there r hundreds of thousands of those postal codes. how can i make this happen... i really appreciate your help..

btw the postal codes to be used is in canada

lmf232s
09-19-2007, 09:31 AM
G.Factor,

In googling how to do this it seems you may find the distance by using latitude and longitude and the calculate the distance. I found many sites that allow you to do the calculation and only 1 site that showed code but in that example they supplied the zip code and either latitude or longitude as a parameter.

Any way I just did a Google search on the following terms:
"Distance between zip codes"
"How to calculate the distance between zip codes"

You might want to toss a .net 2.0 in that search and may be hits that apply to .net.
".net 2.0 calculate distance between zip codes"

I just searched on the above search and here are some sites that might help:

http://www.freevbcode.com/ShowCode.asp?ID=5532
http://www.a1vbcode.com/snippet-3557.asp
http://microsoft.apress.com/feature/53/how-to-create-a-zip-code-service-2005

cgijoe
09-30-2007, 09:12 PM
There are some services on KI you might try - I am pretty sure they are free:
http://kennedyinnovations.com/index.php?option=com_content&task=view&id=70&Itemid=49

G.factor
09-30-2007, 10:19 PM
guys thank you so much for your help, im checking the sites you gave me... i hope its not complicated thing at the end..coz its kinda confusing when u think about it