OS : Linux
PHP Version : 7.4.33
Software : Apache/2.4.6 (CentOS) PHP/7.4.33
Information System : Linux apprendre2 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
Disable Function :
While message catalogs allow you to localize any messages
in your application, there are a number of strings that are used in many
applications for which translations are readily available. Imagine for example you have a list of countries that users can choose from,
and you'd like to display the names of those countries in the language the
user prefers. Instead of translating all those country names yourself in your
application, you can make use of the translations provided by the locale data
included with Babel, which is based on the Common Locale Data Repository
(CLDR) developed and maintained by the Unicode
Consortium. You normally access such locale data through the Locale class provided
by Babel: In addition to country/territory names, the locale data also provides access to
names of languages, scripts, variants, time zones, and more. Some of the data
is closely related to number and date formatting. Most of the corresponding Locale properties return dictionaries, where the
key is a code such as the ISO country and language codes. Consult the API
documentation for references to the relevant specifications. The Locale class provides access to many locale display names related to
calendar display, such as the names of week days or months. These display names are of course used for date formatting, but can also be
used, for example, to show a list of months to the user in their preferred
language:Locale Display Names
1 Introduction
2 The Locale Class
3 Calender Display Names