• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 18. Internationalizing Packages > Step 2: Internationalizing Page Templ...

Step 2: Internationalizing Page Templates

Internationalizing page templates is more interesting than Python code in many ways. You do not have to worry only about finding the correct tags to internationalize; because you can also have heavy nesting, the complexity can become overwhelming. It's a good idea to keep the content of translatable tags as flat as possible; that is, you should try to have translatable text that does not contain much HTML and TAL code.

To achieve internationalization support in Zope 3's page templates, the Zope 3 developers designed a new i18n namespace, which is well documented at http://dev.zope.org/Zope3/ZPTInternationalizationSupport. The three most common attributes are i18n:domain, i18n:translate, and i18n:attributes. Note that the i18n namespace has been back-ported to Zope 2 as well, so you might be familiar with it already.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint