Item1926: To make the page display utf characters: LANG should use $Foswiki::cfg{Site}{Locale} if set
Priority: Normal
Current State: Closed
Released In: 1.1.0
Target Release: minor
Applies To: Engine
Component: I18N
Branches:
I am working on an international language application that
must use utf-8. To my surprise Foswiki "just works" with utf8 (displaying characters), but only when I set
%LANG%
to
$Foswiki::cfg{Site}{Locale}
.
%LANG%
is used in templates to set the HTML "lang" property. Unfortunately, this is not documented, so some plugin authors also use
LANG
(set to
it
or
Deutsch
).
Now I set it this way (in Main.SitePreferences):
but of course the templates should pick up the value set in
$Foswiki::cfg{Site}{Locale}
.
--
ArthurClemens - 16 Aug 2009
What happens if
%LANG%
is
not set to
$Foswiki::cfg{Site}{Locale}
? How does it break?
--
MichaelTempest - 27 Jun 2010
I have not seen anything break, but assuming that a
LANG
setting is needed for utf8, LANG should not be used in a different way. So for now it may be just documentation.
--
ArthurClemens - 15 Aug 2010
Great - setting state back to confirmed.
--
MichaelTempest - 19 Aug 2010
Added
VarLANG topic.
--
ArthurClemens - 19 Aug 2010