[Seaside] Encoding by Swazoo ?

Boris Popov boris at deepcovelabs.com
Thu Nov 2 16:52:52 UTC 2006


Here's how I hacked my Seaside/Swazoo to serve UTF8; its nasty but seems
to work. I wouldn't mind something cleaner though, so feedback from
Janko would still be greatly appreciated.

WAResponse>>initialize
 ...
 stream :=
  EncodedStream on:
   (ReadWriteStream on:
     (ByteArray new: 5000)) encodedBy: (StreamEncoder new: #'utf-8').
 ...

SeasideResource>>convertResponse:
 ...
 swazooResponse entity:
  ((waResponse contents class = EncodedStream)
     ifTrue: [waResponse contents stream contents]
     ifFalse: [waResponse contents contents]).
 ...

Cheers!

-Boris

-- 
+1.604.689.0322
DeepCove Labs Ltd.
4th floor 595 Howe Street
Vancouver, Canada V6C 2T5

boris at deepcovelabs.com

CONFIDENTIALITY NOTICE

This email is intended only for the persons named in the message
header. Unless otherwise indicated, it contains information that is
private and confidential. If you have received it in error, please
notify the sender and delete the entire message including any
attachments.

Thank you.

-----Original Message-----
From: seaside-bounces at lists.squeakfoundation.org
[mailto:seaside-bounces at lists.squeakfoundation.org] On Behalf Of Michel
Bany
Sent: Thursday, November 02, 2006 8:21 AM
To: The Squeak Enterprise Aubergines Server - general discussion.
Subject: [Seaside] Encoding by Swazoo ?

Hi Janko,

Just a quick question.
I tried utf-8 in the content-type but no encoding seems to be performed.
Does Swazoo encode the HTTP response or is it the responsibility of  
the application ?

Thanks,
Michel.

_______________________________________________
Seaside mailing list
Seaside at lists.squeakfoundation.org
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside


More information about the Seaside mailing list