[Seaside] International Characters on different OS

Julian Fitzell julian at beta4.com
Mon Mar 15 18:05:22 CET 2004


Well, it depends -- I have two possible fixes for you.

I recently fixed up the encoding in seaside.  This will also get merged 
into the head soon, probably, but part of the change breaks backwards 
compatibility to some degree since it changes #text: to do encoding by 
default.

Anyway, one solution is to use #encodeText: on your renderer to output 
the text.  This will make sure those characters get replaced with html 
entities.  This assumes your data is in ISO-whatever-hell-it-is rather 
than macroman.  I made a fix to the encoding to make it faster, but this 
shouldn't be necessary for you.

What I eventually came to, was that I had added an xml declaration to 
the output to be XHTML compliant and since it specified UTF-8 encoding, 
the browser was sending data back in UTF-8 when forms were submitted. 
This meant that there were two-byte characters in our data (something I 
had always intended, but had forgotten about).  When you have two-byte 
characters and squeak doesn't support them, doing encoding is 
problematic (unless we change the encoding to account for it I guess). 
Anyway, the solution then was to just remove all the encoding above byte 
127 and as long as you have UTF-8 specified in an xml declaration (I 
posted something about how to do that a few days ago) the browsers seem 
to be pretty happy.  I'm not exactly sure which browsers support UTF-8 
but I did a little google-research and it seemed to be fine going back 
to the 4.0 browsers anyway.

Julian

Sebastián Sastre wrote:

> Hi all,
>    
>     I had a linux server running the an intranet made with seaside and I 
> have the following issue:
>  
>     When some text insertion is made with a windows browser in an 
> object, looking the same object with a linux browser shows bad the 
> international characters like  ñ á é í ó ú Ñ Á É Í Ó Ú. And viceversa.
>  
>     Any ideas of how to deal with this?
>  
>     best regards,
>  
> Sebastián Sastre
> ssastre at seaswork.com.ar <mailto:ssastre at seaswork.com.ar>
> www.seaswork.com.ar <http://www.seaswork.com.ar/>
>  
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Seaside mailing list
> Seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/listinfo/seaside

-- 
julian at beta4.com
Beta4 Productions (http://www.beta4.com)



More information about the Seaside mailing list