![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Newbie
Join Date: Dec 2005
Posts: 1
Rep Power: 0
![]() |
Not sure what to search for, help please
Hi, I am looking for a script that will allow me to search my web database for the closest "retailer"
You've seen these on manufacturer sites where you enter in your zip code and tell it how many miles you are willing to drive and it gives you a list of whoever in return that meet that criteria. The problem is I have no idea what this type of script is called or if anyone has something available for purchase and so on. Can anyone out there give me a hand with this please? Thanks! |
|
|
|
|
|
#2 |
|
Newbie
Join Date: Feb 2006
Posts: 7
Rep Power: 0
![]() |
I suppose you would search for a retailer zip that equals the requested zip then trim a letter from the right of the zip and search for that until it comes up with something.
I'm not pro but would be happy to help you out with that (or is the suggested logic enough for you to have a go?) |
|
|
|
|
|
#3 |
|
Professional Programmer
Join Date: Mar 2005
Location: Glasgow, Scotland
Posts: 321
Rep Power: 4
![]() |
asp1: sounds like an interesting solution. Mostly, where you see this sort of functionality on a website they use a database of rough geographical locations for the ZIP / postal code and a bit of basic geometry, though some of them are even smarter and use route-planning tricks behind the scenes to find a distance that isn't just as the crow flies.
asp1's suggestion does sound like a nice, efficient, simple, tidy hack that would often do just as well though. You might be interested to know it should work equally well with UK postal codes, despite their completely different looking format. I wonder how many nations' area designations this same trick would work for?
__________________
"I'm not a genius. Why do I have to suffer?" |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|