This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Servlets and the fly likes Recognizing the Language preference of the user Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Recognizing the Language preference of the user" Watch "Recognizing the Language preference of the user" New topic
Author

Recognizing the Language preference of the user

Varun Khanna
Ranch Hand

Joined: May 30, 2002
Posts: 1400
Hi
I want to know the language preference of the client browser (cookies are enabled),and among the two options i.e. request attribute ACCEPT_LANGUAGE or cookies which one is better? Is the request one better as it won't be needed to persist them ? or any other way
Thanks
-Varun
[ December 18, 2002: Message edited by: varun Khanna ]

- Varun
Asher Tarnopolski
Ranch Hand

Joined: Jul 28, 2001
Posts: 260
to get a user accepted language you can use
request.getHeader("Accept-Language")
i didn't get your questions about cookies...


Asher Tarnopolski
SCJP,SCWCD
Varun Khanna
Ranch Hand

Joined: May 30, 2002
Posts: 1400
I came across cookie called cllang, though I don't know much about it.
-Varun
 
jQuery in Action, 2nd edition
 
subject: Recognizing the Language preference of the user
 
Similar Threads
help with cookie
what sort of indenting you prefer?
Cookies associated to a Session
Doubt in request Vs response
Java Property File