[Zope] i18n Images
Sergey Volobuev
zope at phpv.khv.ru
Thu Apr 15 00:23:25 EDT 2004
>I should have been clearer. I need to do this in a Zope Page
>Template, specifically, in the Plone 2 header. The DTML is pretty
>straight forward but the xml python is eluding me.
>
>
Plone 2 uses css for caption image. So either you should to switch
css'es based on user language or rewrite the appripriate macro to
generate one or another <img> tag.
Also, you can write a simple python script which returns the image you
need. I've done this once with Localizer, hope you can modify it to work
with Placeless Translation Service
1. Place logo_en, logo_ru or whatever your langusge is to
portal_skins/custom
2. Create the following PythonScript named logo.jpg:
=============
lang=context.portal_languages.getPreferredLanguage()
if lang=='ru':
return context.logo_ru
else:
return context.logo_en
==============
3. Modify to suit your needs.
More information about the Zope
mailing list