I have a very strange problem: I am using a podcast solution called "Podcast Generator" (podcastgenerator.net), and installed on one server the gettext based translation is working perfect (www.fegertest.de/podcasts), while on the other server it simply won't translate (www.feg-erlangen.de/podcasts).
I checked already the following things:
$locale="de_DE";
if (!ini_get('safe_mode'))
putenv("LC_ALL=$locale");
setlocale(LC_ALL, $locale);
bindtextdomain($domain, LOCALE_DIR);
bind_textdomain_codeset($domain, $encoding); //encoding
textdomain($domain);
I have no idea what else could be the reason for it... Any ideas out there?
The locale "de_DE" has to be installed on the server. Run "locale -a grep de_DE" to verify that.
Besides, the environment variable LC_ALL
may not be the right one to set. Set LANG
, LANGUAGE
, and LC_MESSAGES
as well. See http://git.savannah.gnu.org/cgit/gettext.git/tree/gettext-runtime/ABOUT-NLS and read the section "1.2 Using This Package" that explains the exact meaning of the various environment variables in great detail.