You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Saulius Grigaliunas <sa...@gmail.com> on 2005/01/23 12:31:46 UTC

Re[2]: form encoding and utf-8 problems

Hello Aurélien,

> Look at the cocoon's web.xml in WEB-INF and uncomment the following part:


>      <init-param>
>        <param-name>form-encoding</param-name>
>        <param-value>utf-8</param-value>
>      </init-param>

> and It should work.

> Rgds.

Already done that, as I wrote in my first letter. Any other ideas?


-- 
 Saulius



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: form encoding and utf-8 problems

Posted by Timur Izhbulatov <ti...@yxo.ru>.
[ISO-8859-1] Aurйlien DEHAY писал(а): 

> Saulius Grigaliunas wrote:
>> Hello Aurйlien, 
>> 
>>  
>> 
>>> Maybe you can look at the encoding of xsl file, or try with xalan. It
>>> was the only thing I change to make my forms utf-8 aware.
>>  
>> 
>> Well thanks for your help, that didn't work, but I accidently found
>> solution myself, in web.xml I've changed the configuration like this:
>> <init-param>
>>       <param-name>form-encoding</param-name>
>>       <param-value>utf-8</param-value>
>> </init-param>
>> and
>> <init-param>
>>       <param-name>container-encoding</param-name>
>>       <param-value>ISO-8859-1</param-value>  <!-- <- and not utf-8 -->
>> </init-param> 
>> 
>> I don't really understand why it should be iso-8859-1 if everything is
>> encoded in utf-8 in my application, but if it works, that's alright
>> for me :). 
>> 
>> 
> 
> Well, I didn't changedthis configuration and left it commented in my 
> web.xml, that's probably why it works for me. 
> 
> 
> Rgds

That was discussed in the list before. Marc Portier recomended me refering 
to source code to understand how does the container encoding actually works. 
See
http://marc.theaimsgroup.com/?l=xml-cocoon-users&m=109352638022695&w=2 

I personaly don't even touch the container encoding parameter and just set 
the form encoding parameter to utf-8 and use the same encoding in the 
HTMLSerializer. 

Timur 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: form encoding and utf-8 problems

Posted by Aurélien DEHAY <ad...@zorel.org>.
Saulius Grigaliunas wrote:
> Hello Aurélien,
> 
> 
> 
>>Maybe you can look at the encoding of xsl file, or try with xalan. It
>>was the only thing I change to make my forms utf-8 aware.
> 
> 
> Well thanks for your help, that didn't work, but I accidently found
> solution myself, in web.xml I've changed the configuration like this:
> <init-param>
>       <param-name>form-encoding</param-name>
>       <param-value>utf-8</param-value>
> </init-param>
> and
> <init-param>
>       <param-name>container-encoding</param-name>
>       <param-value>ISO-8859-1</param-value>  <!-- <- and not utf-8 -->
> </init-param>
> 
> I don't really understand why it should be iso-8859-1 if everything is
> encoded in utf-8 in my application, but if it works, that's alright
> for me :).
> 
> 

Well, I didn't changedthis configuration and left it commented in my 
web.xml, that's probably why it works for me.


Rgds

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: form encoding and utf-8 problems

Posted by Marc Portier <mp...@outerthought.org>.
Saulius,

you can find an explanation here:
http://wiki.apache.org/cocoon/RequestParameterEncoding?action=highlight&value=container-encoding
(with highlight of the section that might interest you most)

there is more in the mail archives of this list, since this has been 
touched upon quite a lot.

the short answer on your remark: your application maybe codes everything 
in utf-8, but the web-container (jetty or tomcat or...) is not.

cocoon uses the two parameters to correct the applied container-decoding 
  into the by you wanted form-encoding

regards,
-marc=


Saulius Grigaliunas wrote:
> Hello Aurélien,
> 
> 
> 
>>Maybe you can look at the encoding of xsl file, or try with xalan. It
>>was the only thing I change to make my forms utf-8 aware.
> 
> 
> Well thanks for your help, that didn't work, but I accidently found
> solution myself, in web.xml I've changed the configuration like this:
> <init-param>
>       <param-name>form-encoding</param-name>
>       <param-value>utf-8</param-value>
> </init-param>
> and
> <init-param>
>       <param-name>container-encoding</param-name>
>       <param-value>ISO-8859-1</param-value>  <!-- <- and not utf-8 -->
> </init-param>
> 
> I don't really understand why it should be iso-8859-1 if everything is
> encoded in utf-8 in my application, but if it works, that's alright
> for me :).
> 
> 

-- 
Marc Portier                            http://outerthought.org/
Outerthought - Open Source, Java & XML Competence Support Center
Read my weblog at                http://blogs.cocoondev.org/mpo/
mpo@outerthought.org                              mpo@apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re[2]: form encoding and utf-8 problems

Posted by Saulius Grigaliunas <sa...@gmail.com>.
Hello Aurélien,


> Maybe you can look at the encoding of xsl file, or try with xalan. It
> was the only thing I change to make my forms utf-8 aware.

Well thanks for your help, that didn't work, but I accidently found
solution myself, in web.xml I've changed the configuration like this:
<init-param>
      <param-name>form-encoding</param-name>
      <param-value>utf-8</param-value>
</init-param>
and
<init-param>
      <param-name>container-encoding</param-name>
      <param-value>ISO-8859-1</param-value>  <!-- <- and not utf-8 -->
</init-param>

I don't really understand why it should be iso-8859-1 if everything is
encoded in utf-8 in my application, but if it works, that's alright
for me :).


-- 
 Saulius



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: form encoding and utf-8 problems

Posted by Aurélien DEHAY <ad...@zorel.org>.
Saulius Grigaliunas wrote:
> Hello Aurélien,
>
>
>>Look at the cocoon's web.xml in WEB-INF and uncomment the following part:
>
>
>
>>     <init-param>
>>       <param-name>form-encoding</param-name>
>>       <param-value>utf-8</param-value>
>>     </init-param>
>
>
>>and It should work.
>
>
>>Rgds.
>
>
> Already done that, as I wrote in my first letter. Any other ideas?
>
>

Maybe you can look at the encoding of xsl file, or try with xalan. It
was the only thing I change to make my forms utf-8 aware.

Rgds.