The goal of internationalization and localization is to allow a single Web application to offer its content in languages and formats tailored to the audience.
Essentially, Django does two things:
Obviously, translation depends on the target language, and formatting usually
depends on the target country. This information is provided by browsers in
Accept-Language header. However, the time zone isn’t readily available.
The words “internationalization” and “localization” often cause confusion; here’s a simplified definition:
Translation and formatting are controlled by
USE_L10N settings respectively. However, both features involve
internationalization and localization. The names of the settings are an
unfortunate result of Django’s history.
Here are some other terms that will help us to handle a common language:
llor a combined language and country specification of the form
pt_BR. The language part is always in lower case and the country part in upper case. The separator is an underscore.
Accept-LanguageHTTP header using this format. Examples:
pt-br. Language codes are generally represented in lower-case, but the HTTP
Accept-Languageheader is case-insensitive. The separator is a dash.