Current

This document is valid for the current version of Plone.

Automatically translated message ids

by Plone Documentation Team last modified Dec 12, 2009 10:33 PM
Contributors: Mikko Ohtamma, Martin Aspeli, Kamon Ayeva, Israel Saeta Pérez
When messages are translated automatically and you don't need to call context.translate()

Plone will automatically perform translation for message id objects which are outputted in page templates.

The following code would translate my_translateable_text to the native language activated for the current page.

<span tal:content="view/my_translateable_text">

Note that since my_translateable_text is zope.i18nmessageid.message.Message containing its own gettext domain information, the i18n:domain attribute in page templates does not affect message ids declared through message factories.