[Zope-CMF] Re: Minor problem with local_pt and non-ascii portal properties

yuppie y.2007- at wcm-solutions.de
Fri Jun 22 06:13:27 EDT 2007

Charlie Clark wrote:
> it is not possible to do anything with a local_pt in the ZMI if any of 
> the Portal properties are non-ascii.
> I have a site called "Düsseldorf" with a local_pt containing some 
> customisations for the homepage. With CMF 2.0 and Zope 2.9 this is not a 
> problem but CMF 2.1 and Zope 2.10 will cause an error presumably due to 
> the switch to Zope 3 PageTemplates. The tracaback is below.
> The first question is: am I doing something wrong using local_pt like 
> this? If not the second question is: what's the best way around this?

Please try to use a script and Products.CMFDefault.utils.decode. In CMF 
2.1 *all* strings passed to a template have to be unicode. Maybe 
'portal_title' defined in getMainGlobals works for you, at least it 
shows how to use 'decode'.

HTH, Yuppie

More information about the Zope-CMF mailing list