one thing that bothered me on a recent project was that even in a browser  
view I have to decode "cooked_body" for those Satanic browsers Safari and  
Internet Explorer.

I looked a bit into the system and saw that we still use ReST in a very  
Wallace & Gromit way: ReST encodes the generated HTML using the default  
encoding from zope.conf and we promptly decode it back to unicode every  
time we want to display it, and make sure default-encoding and  
rest-encoding match. Adding "output='unicode' to Document's CookedBody()  
removes the double-encoding and doesn't break any tests. Would it be okay  
to add this for Document and News objects and adjust the views  
accordingly? I assume an upgrade step would need to run CookedBody() to  
convert existing "cooked_text" to unicode.

Charlie Clark
Managing Director
Clark Consulting & Research
German Office
Helmholtzstr. 20
D- 40215
Tel: +49-211-600-3657
Mobile: +49-178-782-6226
Zope-CMF maillist  -  Zope-CMF@zope.org

See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests

Reply via email to