Kyle Smith wrote:
> Per Jessen wrote:
>> Kyle Smith wrote:
>>> Per Jessen wrote:
>>>> See
>>>> "Thank you for taking the time to write to us, but this is not
>>>> a bug. And RTFM". (RTFM is my interpretation of the rest).
>>>> And that only took a little more than a month. Thanks very much.
>>>> Can anyone here tell me why the CLI behaviour reported is not a bug?
>>>> An explicit manual reference will do.
>>>> Btw, I brought it up here already:
>>>> /Per
>>> I don't mean to be rude, but I have never heard of or used these
>>> functions and never written a multi-lingual PHP site.  I RTFM'd and
>>> found this:
>>> Then I read the first sentence defining the second parameter, which
>>> states: If /locale/ is *NULL* or the empty string /""/, the locale
>>> names will be set from the values of environment variables with the
>>> same names as the above categories, or from "LANG".
>>> Pretty straight-forward.
>> Did you bother reading the bug report?  The PHP CLI ignores the locale
>> setting from the environment such as set by setting LC_ALL. Your
>> quoting from the manual does not change that.  Now, if you can find a
>> place in the manual that says the CLI will ignore whatever locale
>> settings are set in the environment, we can talk again.
>> /Per
> I don't think your aggressive attitude to the situation is helping
> anyone here.   The manual *explicitly* states that using
> setlocale(LC_xyz,'') will use the environment variable setting for that
> LC_xyz option.  This *implies* that, by default, those environment
> variables are not used.
> Perhaps it should use the environment variables, instead?  At any rate,
> it's not a "bug", since someone(s) did it that way on purpose.  You
> could file a feature request.

Sorry, just want to point out a difference, that I see, in the code
examples.  Not trying to start anything here...

So, what does the example you provide have to do with the ops code
example in the bug report?

OPS example code from bug report
LC_ALL=de_DE.utf8 php -r "print strftime('%B');"

your example

I don't see him using the above function in his example.

>From what I can tell, the op is trying to set the locale /AT/ the cli,
not from within the script.

I guess my first debugging question would be:

Can you successfully set other LC_xyz categories, besides the LC_ALL, in
the same manor that your example shows?

If it works with the others (LC_COLLATE, LC_CTYPE, etc...) then I
/would/ call this a bug.  Unless it has been explicitly stated somewhere
that the op has not found that "This works with all but the LC_ALL

Just my 2 bits worth.

Jim Lucas

PHP General Mailing List (
To unsubscribe, visit:

Reply via email to