Just had this question come up. Basically you need to add a character encoding filter that does a request.setCharacterEncoding("UTF-8"); before anyone reads the request.
See this thread: http://www.nabble.com/Handle-Japanese-characters-from-jsp-page-into-ActionClass-td24686908.html On Wed, Jul 29, 2009 at 11:23 AM, Vítor Souza <vitorso...@gmail.com> wrote: > > Hi, > > I've searched the entire afternoon for something about this, tried many > many > things, but so far nothing has worked. Please, help. > > When I type my name - "Vítor" - in a <s:textfield />, the value "VÃtor" is > set at the action's property. > > I've tried using <input type="textfield" /> to see if the problem was in > the > Struts tags, but the problem persisted. > > I've added the parameter acceptcharset="UTF-8" to <s:form />, but didn't > make a difference. > > I copied the source code of ParametersInterceptor from XWork 2.1.2's source > to debug. When it calls retrieveParameters(ac) in line 173, the value of > the > name property in the map is already corrupted. > > My web pages all start with: > > <%@ page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%> > > My SiteMesh decorator also declares in the <head> section: > > <meta http-equiv="content-type" content="text/html; charset=utf-8" /> > > I've also deactivated SiteMesh to see if it was causing the problem, but > no. > > I've set and unset "struts.i18n.encoding=UTF-8" in struts.xml and > struts.properties, but it doesn't make a difference, since that is the > default anyways, right? > > I've tried using Tomcat 6.0.20 and Tomcat 5.5.27, both with same results. > > I've added URIEncoding="UTF-8" to the <Connector /> definition in Tomcat's > server.xml, but didn't work either. > > I really don't know what else to do. Any ideas? > > Thanks a lot, > > Vítor Souza > > > -- > View this message in context: > http://www.nabble.com/Accented-characters-replaced-during-parameter-input-tp24721592p24721592.html > Sent from the Struts - User mailing list archive at Nabble.com. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: user-unsubscr...@struts.apache.org > For additional commands, e-mail: user-h...@struts.apache.org > >