swa66 - 11:32 pm on Jul 1, 2012 (gmt 0)
First I'd see why they need it. If they can live with a certain % of inaccurate results or "don't know" cases and deduce from there what strategy and what certainty level I'd want.
I'll assume it's a sales relating thing - not a legal requirement or something that's secret somehow or so.
I'd use 3 modes to determine what I do:
- know mode: you know what it should be
--- you still offer a "change" -> track it - if it's used a lot you did not know after all.
- doubt mode: you have a guess at best: up to the custoemr what to do, but
--- make sure to make the "change" stand out and track it heavily: it might get the IP reclassified if there's a consistent answer from the users (confirming your suspicion as good enough), or it might show there's no way to know
- ask mode: you know you do not know or you know the users tell you inconsistent answers of what it should be, or you know it's politically incorrect to assume -> ask the user.
If a user resets your choice:
- know mode: just record them and review if you get many changes
- doubt mode: quite interesting to try to change the mode
- ask mode: just record them and review if you get systematic answers
Always: store it in a cookie for that user so they get the view they want.
As input in your choice, use a combination:
- a for-pay database like Maxmind's city one -> it gives the location of an IP pretty reliable if it's not from "funny" ISPs. [Maxmind city one gives longitude and lattitude -> islands make that easy to box it in - no need to ahve a list of cities/zip codes etc.]
- timezone and/or langauge settings in the browser can help too.
- and obviously a reclassify database based on you reclassification answers.
That's the best you'll get it I think.
I'd have a look at how apple does things:
www.apple.com: US shop
www.apple.nl: Dutch shop
www.apple.be: asks the language (too politically loaded to set it yourself), gives Belgian shop in chosen language.
It's not state based, but it shows maybe that if they choose to now always try to detect it, there might be a good reason for smaller companies not to make the choice for the visitor either - or at least not in all cases.