[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ale] Can I identify the country of origin?
- Subject: [ale] Can I identify the country of origin?
- From: dchambers at snapserver.com (Denny Chambers)
- Date: Wed, 25 Sep 2002 10:16:38 -0500
I am working on an app right now that does this. We are using java
servlets which makes this real easy. There are three methods
ServletRequest.getLocale(), ServletRequest.getLocales() and
ServletResponse.setLocale(). Which every programming language you use,
what you want to look for is the HTTP header "Accept-Language". This can
actually be more than one language. There are ordered by the users
preference. While this will not guarantee what contry to user is from,
it will give you an idea what language he/she would like to see.
Jim Lynch wrote:
>I know it is an off topic question, but this group represents some of
>the best minds in town. My boss asked me if I could identify the
>country of origin of systems connecting to our web page. I think he
>wants to automate the language displayed. I told him I wasn't aware of
>anything, but decided I'd ask a larger audience before I gave him an
>absolute no. I know I can do a name lookup and sometimes figure out the
>country, but that won't always work.
>This message has been sent through the ALE general discussion list.
>See http://www.ale.org/mailing-lists.shtml for more info. Problems should be
>sent to listmaster at ale dot org.
This message has been sent through the ALE general discussion list.
See http://www.ale.org/mailing-lists.shtml for more info. Problems should be
sent to listmaster at ale dot org.