--On 25. Juli 2007 15:12:37 +0200 Andreas Elvers <[EMAIL PROTECTED]> wrote:

Andreas Jung wrote:

<span tal:replace="structure python:u'deja vu'"></span>

Likely because you're using the u'...' notation. However I have no clue
why do you want to work with unicode strings this way...this looks
somewhat artificial (independent of the behavior).

You are right. The u'...' notation does no good in a page template. It was
just a test to understand unicode strings in page templates.

Moving the string out into a python script and calling the template
gives me deja vu as expected.

example script:
mystring = u'déjà vu'
return context.template(mystring=mystring)

example template:
mystring: <span tal:replace="structure options/mystring"></span>

or use python: unicode(...) inside TALES - BUT ONLY if necessary.


Attachment: pgpb5IBNQa77B.pgp
Description: PGP signature

Zope maillist  -  Zope@zope.org
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-dev )

Reply via email to