[Zope3-Users] i18n of an image

Chris Withers chris at simplistix.co.uk
Fri Oct 28 04:12:13 EDT 2005


Andreas Jung wrote:
> i18n:attributes just replaces the attributes with content from the 
> catalog file.
> 
>> How can change an image depend on the user location?
> 
> how about i18n:attributes="src python: test(your_condition, 'someurl1', 
> 'someurl2')" ?

I tend to create a folder of the image name, with actual images called, 
for example, 'en' 'fr' 'de', etc and then have an index_html python 
script aquirable from fromwhere that picks the right image, falls back 
to a default if one isn't available, and renders it. This also means you 
can juse use normal image tags...

cheers,

Chris

-- 
Simplistix - Content Management, Zope & Python Consulting
            - http://www.simplistix.co.uk



More information about the Zope3-users mailing list