Dmitriy Lyalyuev
Dmitriy Lyalyuev

Reputation: 9

Russian WikiWords in FosWiki

I'm trying to set up support for the Russian language wiki. It turns out nothing. Russian language appears in the texts, but can't configure WikiWords.

When LocaleRegexes=1, UseLocale=1, Site Locale = ru_RU.utf8 Russian words are not recognized as the WikiWords. If LocaleRegexes=0 and filled UpperNational and LowerNational all the Russian words are recognized as a valid WikiWord. Even in lowercase.

Who can help with the configure wiki?

# uname-a
Linux wiki 3.2.0-24-virtual #37-Ubuntu SMP Wed Apr 25 12:51:49 UTC 2012 
i686 i686 i386 GNU/Linux

# perl-v

This is a perl 5, version 14, subversion 2 (v5.14.2) built for 
i686-linux-gnu-thread-multi-64int
(with 56 registered patches, see perl-V for more detail)

# locale
LANG=en_US.UTF-8
LANGUAGE=en_US:en
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=

# locale-a
C
C.UTF-8
en_AG
en_AG.utf8
en_AU.utf8
en_BW.utf8
en_CA.utf8
en_DK.utf8
en_GB.utf8
en_HK.utf8
en_IE.utf8
en_IN
en_IN.utf8
en_NG
en_NG.utf8
en_NZ.utf8
en_PH.utf8
en_SG.utf8
en_US.iso88591
en_US.utf8
en_ZA.utf8
en_ZM
en_ZM.utf8
en_ZW.utf8
POSIX
ru_RU.iso88591
ru_RU.iso88595
ru_RU.utf8
ru_UA.utf8

Upvotes: 0

Views: 201

Answers (1)

nuddlegg
nuddlegg

Reputation: 141

This has been asked on the mailing recently. In short:

international WikiWords don't work, sorry.

In fact I'd argue to disable automatic linking of WikiWords all together using

  • Set NOAUTOLINK = on

in your SitePreferences. Instead, use explicit linking using the bracket notation [[...]].

Then use

$Foswiki::cfg{UseLocale} = 0; 
$Foswiki::cfg{Site}{LocaleRegexes} = 1; 
$Foswiki::cfg{Ldap}{CharSet} = 'utf-8'; 

If you still would like to enable locales, then remove the -T flag from all perl scripts. You can't have both: locales and taintedness checks enabled in perl.

Locales in perl inject a lot of tainted strings coming from the system. As such perl isn't able to distinguish strings that rightfully should be considered tainted coming from the user.

Upvotes: 1

Related Questions