struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chalmers, Doug" <>
Subject Russian I18n problems
Date Wed, 22 Jan 2003 10:23:42 GMT
Hi all,

I have a problem which isn't strictly Struts related but I'm hoping someone has done this
before. (Thanks to Craig McClanahan and Aaron Rustad for their help so far on this.)

I'm trying to get a Russian version of an existing application working. So far, I've set up
Russian text resources and these work fine by specifying the following line at the top of
the JSP (at the top of a template JSP in this case):

<%@ page contentType="text/html;charset=UTF-8" language="java"%> and this line in the
Action class:

response.setContentType("text/html; charset=UTF-8"); 

This is fine, but it won't submit and maintain (show on page again) Russian text when entered
in e.g. a Struts Text Area

In order to get submitted text working I've also done the following:

Inserted the following in web.xml:


and having the following line at the top of the JSP page (NB, not at the top of the template
as above)

<%@ page contentType="text/html;charset=windows-1251" language="java"%> and

response.setContentType("text/html; charset=windows-1251");

The problem is that both will not work together. I've seen solutions that utilise HttpServletRequest.setCharacterEncoding(),
but I can't use that as we're stuck with Weblogic 5.1 which only uses EE1.2.1. I've also seen
the use of filters but they utilise the Servlet2.3 spec too.

Any help with this is greatly appreciated. Getting both working but not together is a bit
maddening as you can imagine!

Software used:

Weblogic 5.1
Struts 1.0.2
JDK1.2 / EE1.2.1
IE 5 - submits charset Cp1251


Doug Chalmers
Software Developer
Petrotechnics Ltd.
Tel. +44 (0) 1224 337236

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message