[pmwiki-users] Multilanguage and XLPages

Rogutės Sparnuotos rogutes at googlemail.com
Sun Dec 27 13:51:00 CST 2009

Mike (2009-12-27 12:30):
> Hello everyone,
> I am using multilanguage.php on my website to offer it in three 
> languages, working fine.
> Now I'm adding additional features to the page, like e.g. a contact form 
> (which I took from emailform).
> That way I came across the internationalization options around XLPage 
> etc. Obviously I'd like all the strings in emailform to be translated to 
> the respective language the user has chosen.
> I.e., I need to make XLPage work together with multilanguage.
> Is this documented anywhere?

It is described in the cookbook pages of both multilanguage recipes. Excerpts

1. http://pmwiki.org/wiki/Cookbook/MultiLanguage
   If you use translation pages (see: Internationalizations) you probably want
   to switch the XLPage definition too. To do this, use an if statement in
   your local configuration (config.php):
   if ($_COOKIE['userlang'] == 'XX') {
   Use PmWikiXX.XLPageLocal for your own phrases

2. http://pmwiki.org/wiki/Cookbook/MultiLanguageViews
   For changing the wiki interface language according to the language view add
   to conflig.php something like this, after including the langviews.php
   if ($_COOKIE['userlang'] == 'de') {
   etc. for other language's XL pages

--  Rogutės Sparnuotos

More information about the pmwiki-users mailing list