[horde] Horde Turkish Language

Jan Schneider jan at horde.org
Mon Jul 9 13:20:56 UTC 2012


Zitat von bagcib at itu.edu.tr:

> Alinti Hannes Werner <jgoethe at gmail.com>
>
>> Hello,
>>
>> I used to have Horde 3 running with Turkish language support although there
>> is a php-bug for Turkish. Does anyone run Horde 4 with Turkish language
>> support, does it work?
>>
>
> Yes, our webmail system is H4 and works with default turkish. But  
> for this, we edit some of source fiiles.
>
> First; edit "config/nls.php" and enable turkish settings (just  
> comment if statement)
>
> [root at server ~]# tail -n 7 config/nls.php
> /* Turkish locales. */
> //if (version_compare(PHP_VERSION, '6', 'ge')) {
>     $horde_nls_config['aliases']['tr'] = 'tr_TR';
>     $horde_nls_config['charsets']['tr_TR'] = (strpos(PHP_OS, 'BSD')  
> === false) ? 'ISO-8859-9' : 'ISO8859-9';
>     $horde_nls_config['languages']['tr_TR'] = 'T&#xfc;rk&#xe7;e';
>     $horde_nls_config['spelling']['tr_TR'] = '-d tr';
> //}
>
>
> Second, edit "/usr/share/pear/Horde/Registry.php" and overrite local  
> setting ctype as utf8-eng
>
> [root at server ~]# head -n 2517 /usr/share/pear/Horde/Registry.php | tail -n 9
>         $lang_charset = $lang . '.UTF-8';
>         if (setlocale(LC_ALL, $lang_charset)) {
>             putenv('LC_ALL=' . $lang_charset);
>             putenv('LANG=' . $lang_charset);
>             putenv('LANGUAGE=' . $lang_charset);
>             setlocale(LC_CTYPE, 'en_US.UTF8');        // <------- this line
>         } else {
>             $changed = false;
>         }
>
>
> This configuration works. We use H4 with default turkish and no  
> problem. This is not correct solution, but until php6, this way is  
> usefull.

Well, this might be viable workaround until PHP is fixed, if you run  
this line conditionally, i.e. only if using Turkish, and if you set  
the locale to 'C' instead. This will still break a few things, but  
that might be worth it to get Turkish working out of the box.

-- 
Jan Schneider
The Horde Project
http://www.horde.org/



More information about the horde mailing list