myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rafa PĂ©rez" <raja...@gmail.com>
Subject Re: [Trinidad] inputText special characters
Date Fri, 11 Apr 2008 06:22:46 GMT
I had the same problem. I do not know why, but in the very first request,
the character encoding of the request is UTF-8 and if you have configured
your application to use ISO-8859-1, it gets ignored.
The only solution I found was to introduce a filter for setting the charset,
something like

((HttpServletRequest)request).getSession().setAttribute(ViewHandler.CHARACTER_ENCODING_KEY,
''ISO-8859-1')


HTH,

-- Rafa

On Thu, Apr 10, 2008 at 11:34 PM, Mathias Walter <mathias.walter@gmx.net>
wrote:

> Hi,
>
> > You may have ISO-8859-1 set to JSP response.
>
> I don't use JSP, I'm using Facelets. But I give it a try and changed the
> XML
> encoding. But it doesn't help.
>
> As soon as I submit the form, the characters will be converted.
>
> Why does this happens with IE and not with FF?
>
> Ah, I forgot to mention that form is partially submitted with a
> <tr:commandLink "partialSubmit=true">.
>
> --
> Regards,
> Mathias
>
> > Instead, please use UTF-8, like
> > <jsp:directive.page contentType="text/html;charset=UTF-8"/>
> > Hope this helps
> > Kenneth
> >
> > Mathias Walter wrote:
> > > Hi,
> > >
> > > I've some trouble with special characters (i. e. german umlauts) and
> > > tr:inputText. With IE 6, the characters will be converted
> > to some unreadable
> > > two-byte codes, but with FF2 it works well.
> > >
> > > I'm using Trinidad 1.2.7, Sun JSF RI 1.2 and Facelets.
> > > The head of the rendered page is
> > >
> > > <?xml version="1.0" encoding="ISO-8859-1" ?>
> > > <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
> > > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd" >
> > >
> > > How can I fix this?
> > >
> > > --
> > > Kind regards,
> > > Mathias
> > >
> > >
>
>

Mime
View raw message