[Seaside] Accent encoding problem with seaside and scriptaculous

Florian Minjat florian.minjat at emn.fr
Mon Dec 18 09:45:49 UTC 2006

Philippe Marschall wrote:
> 2006/12/18, Florian Minjat <florian.minjat at emn.fr>:
>> Hi,
>>    I spent two hours yesterday to figure that out.
>>    I have a form with an ajax button (scriptaculous) which trigger the
>> form when clicked. But if I have some accented or special characters
>> in the input fields of the from, they are stored with errors.
>>    At first I tought it was
>> HTTPRequest>>decodeUrlEncodedForm:multipleValues: and
>> String>>unescapePercents which were broken. Then that it's the
>> scriptaculous script which is guilty.
>>    This bug is pretty obvious to test, at least on my squeak
>> (seaside2.6b1-mb.127 Scriptaculous-lr.162) : juste use the form part
>> of the scriptaculous example. If you input 'forêt' you get a
>> forêt in seaside. The POST variable value transmitted to seaside is
>> 'for%C3%AAt'. But the URL-encode value for the character 'ê' should be
>> '%ea'.
>>    But I tried this example on scriptaculous.seasidehosting.st, and it
>> is displayed well with the same post value. So the guilty should be
>> seaside or Kom.
>>    Anyone as an idea how to make seaside understand the percented
>> values the way it should ?
> They work unless you have some combination that doesn't work
> - Squeak version

I made a squeak/seaside/scriptaculous image based on Squeak3.8.1a-6666.

> - Kom adaper (WAKom/WAKomEncoded/WAKomEncoded39)

Thoses classes are present in my image. I use KomHttpServer-gk.14 and 
KomServices-gk.3. Should I use WAKomEncoded instead of WAKom ? How 
should I do ? By using 'WAKomEncoded startOn: 9090' to start seaside ?

> - Client encoding

I specified the use of the charset 'ISO-8859-1' in WAHtmlRoot>>charSet 
and WAResponse>>defaultValueForContentType. The header of the 
scriptaculous post with the percented values says 'Content-Type: 
text/html; charset=ISO-8859-1'.

> - desired String class (WideString, (utf-8) ByteString)

What should I do with theses String ? They are present in my image.


More information about the Seaside mailing list