|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2018-06-21 14:07 UTC] jluc at no-log dot org
Description: ------------ --- From manual page: http://www.php.net/function.strftime --- "Format the time and/or date according to locale settings. Month and weekday names and other language-dependent strings respect the current locale set with setlocale()." BUT day of week are allways english, whatever the locale The given example is : setlocale(LC_TIME, "fr_FR"); echo strftime(" in French %A and"); but the output is not displayed in http://www.php.net/function.strftime AMOF, output is in French Thursday and Thu Which is not the expected : "in French Jeudi and Jeu" Expected result: ---------------- Either documentation is wrong and setlocale is not efficient with dayofweeks names Either this is a bug Anyway, the output for this example should be included in the documentation (not only the PHP source) as it's done for other examples. PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Sat May 02 11:00:02 2026 UTC |
I can't reproduce this issue. Please could you run on the command line: ``` locale -a | grep fr ``` and also run ``` $result = setlocale(LC_TIME, "fr_FR"); echo strftime(" in French %A and"); var_dump($result); ``` and give the output for both. The simplest explanation would be that the fr_FR locale is not available on your system for whatever reason.