Try:
putenv("LANG=de_DE") . '<br>'; putenv("LC_ALL=de_DE") . '<br>'; setlocale(LC_ALL, "de_DE", "german") . '<br>';
I would have done this:
putenv("LANG=de_DE"); putenv("LANGUAGE=de_DE"); // better to be paranoid, works for me ;-) putenv("LC_ALL=de_DE"); setlocale(LC_ALL, "de_DE", "german");
(see some user comments in php manual)
Then you can try to reload the apache webserver (because of the gettext cache, which could hide modifications). "/etc/init.d/apache reload" on a Debian GNU/Linux system. "/etc/rc.d/httpd reload" on RedHat likes
Perhaps check german locales are correctly installed on the *nix server.
(php uses the setlocale() system call). Yes, locales are system specific. It should be better documented in the php manual :(
> btw! on win32 it works :(
I solved it the stupid way, because locale names are different on *nix and windows (ex: fr_BE vs French_Belgium). On my test systems, some aliases were common (french, dutch, german) but the path where php looks for the mo file was different (ex fr_BE vs french, de_DE vs german). So I simply copied the /de_DE dir to /german and so on. (for french, I had fr/, fr_BE/ and french/ as dir for it to work on 2 linux servers and 1 test NT server :(
Hope it helps,
-- Christophe Chisogne Developper, Publicityweb sprl http://www.publicityweb.com
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php