note 47915 deleted from function.setlocale by derick
| From: | derick@php.net | Date: | Tue, 30 Aug 2005 11:24:30 +0000 |
| Subject: | note 47915 deleted from function.setlocale by derick | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-94416@lists.php.net to get a copy of this message | ||
Note Submitter: NetPanther at gmx dot net
----
string setlocale ( mixed category, string locale [, string ...])
In many cases I experienced that setlocale() does not work with date(), no matter which value you
use as 'string locale':
<?php
setlocale(LC_ALL, 'de_DE@euro', 'de_DE', 'de-DE', 'de',
'ge', 'de_DE.ISO_8859-1', 'German');
echo date(F);
?>
Instead you might want to use an array in order to store locale month-names, but in most cases using
strftime() works fine, as well:
<?php
setlocale(LC_ALL, "de_DE");
echo strftime("%B");
?>