string setlocale( string $category, string $locale [, string $... )
(PHP 4, PHP 5)
| $category | The category of locale information to set. |
|---|---|
| $locale | If NULL or empty string, the locale names modified will be set based upon environment variables. If $locale is “0”, no settings are affected and instead the current setting is returned. If you pass an array for the $locale, the system will attempt to set each value from the array and the list of parameters which follows it. |
| RETURNS | The current setting for the locale if $locale is set to “0”. |
This method will set locale information for various PHP functions which are locale-specific. An example of these functions are strcoll, strftime, and localeconv.
| LC_ALL | Indicates modifications affect all categories (listed below) |
|---|---|
| LC_COLLATE | Localed settings only affect string collations. |
| LC_CTYPE | Only character class methods and conversions are affected. |
| LC_MONETARY | Only monetary functions are affected. |
| LC_NUMERIC | Only decimal separator functions are affected. |
| LC_TIME | Only date and time functions are affected. |
| LC_MESSAGES | Only system responses are affected. |