Re: setlocale madness... please help!

From: Date: Fri, 03 Nov 2006 17:05:26 +0000
Subject: Re: setlocale madness... please help!
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-244153@lists.php.net to get a copy of this message
# jochem@iamjochem.com / 2006-11-03 14:51:39 +0100: > 1. running the command 'locale -a' returns the following [shortened] list: > > C > de_DE > dutch > en_GB > nl_NL > nl_NL@euro > nl_NL.iso88591 > nl_NL.iso885915@euro > nl_NL.utf8 > nl_NL.utf8@euro > POSIX > > 2. running the following from the commandline returns "en_GB" (meaning > the locale was set correctly) > > php -r 'var_dump(set_locale(LC_ALL, "en_GB"))'; > > 3. running the same code via the webbrowser (it is Apache2 and yes I > have restarted it!) always returns FALSE (meaning the locale was not > set correctly) what happens if you run locale -a from apache? > in fact I can set any installed locale I want on the commandline BUT > trying to set any other than the originally installed "nl_NL@euro" in > code running via Apache results in FALSE being returned and the locale > not being set. > > has anybody got a clue for me? You don't mention what warning(s) the failing setlocale() call produces. -- How many Vietnam vets does it take to screw in a light bulb? You don't know, man. You don't KNOW. Cause you weren't THERE. http://bash.org/?255991

« previous php.general (#244153) next »