From 176c4545f626f74d34cb441c5f254d09dd63eb91 Mon Sep 17 00:00:00 2001 From: Georg Bauer Date: Wed, 12 Oct 2005 11:48:27 +0000 Subject: changed layout of language stuff to be oriented after locale names, not language names (from accept-language header) git-svn-id: http://code.djangoproject.com/svn/django/branches/i18n@848 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/conf/locale/pt-br/LC_MESSAGES/django.mo | Bin 5588 -> 0 bytes django/conf/locale/pt-br/LC_MESSAGES/django.po | 283 ------------------------- django/conf/locale/pt_BR/LC_MESSAGES/django.mo | Bin 0 -> 5588 bytes django/conf/locale/pt_BR/LC_MESSAGES/django.po | 283 +++++++++++++++++++++++++ django/utils/translation.py | 10 +- docs/translation.txt | 20 +- 6 files changed, 302 insertions(+), 294 deletions(-) delete mode 100644 django/conf/locale/pt-br/LC_MESSAGES/django.mo delete mode 100644 django/conf/locale/pt-br/LC_MESSAGES/django.po create mode 100644 django/conf/locale/pt_BR/LC_MESSAGES/django.mo create mode 100644 django/conf/locale/pt_BR/LC_MESSAGES/django.po diff --git a/django/conf/locale/pt-br/LC_MESSAGES/django.mo b/django/conf/locale/pt-br/LC_MESSAGES/django.mo deleted file mode 100644 index 395b7554e3..0000000000 Binary files a/django/conf/locale/pt-br/LC_MESSAGES/django.mo and /dev/null differ diff --git a/django/conf/locale/pt-br/LC_MESSAGES/django.po b/django/conf/locale/pt-br/LC_MESSAGES/django.po deleted file mode 100644 index c005bb39d8..0000000000 --- a/django/conf/locale/pt-br/LC_MESSAGES/django.po +++ /dev/null @@ -1,283 +0,0 @@ -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. -# -#, fuzzy -msgid "" -msgstr "" -"Project-Id-Version: django\n" -"Report-Msgid-Bugs-To: jpaulofarias@gmail.com\n" -"POT-Creation-Date: 2005-10-11 09:11-0300\n" -"PO-Revision-Date: 2005-10-11 09:12GMT-3\n" -"Last-Translator: João Paulo Farias \n" -"Language-Team: Português do Brasil \n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" - -#: conf/admin_templates/404.html:3 conf/admin_templates/404.html.py:7 -msgid "Page not found" -msgstr "Página não encontrada" - -#: conf/admin_templates/404.html:9 -msgid "We're sorry, but the requested page could not be found." -msgstr "Desculpe, mas a página requisitada não pode ser encontrada." - -#: conf/admin_templates/index.html:26 -#: conf/admin_templates/changelist_generic.html:8 -msgid "Add" -msgstr "Adicionar" - -#: conf/admin_templates/index.html:32 -msgid "Change" -msgstr "Modificar" - -#: conf/admin_templates/index.html:42 -msgid "You don't have permission to edit anything." -msgstr "Você não tem permissão para edição." - -#: conf/admin_templates/index.html:50 -msgid "Recent Actions" -msgstr "Ações Recentes" - -#: conf/admin_templates/index.html:51 -msgid "My Actions" -msgstr "Minhas Ações" - -#: conf/admin_templates/index.html:55 -msgid "None available" -msgstr "Nenhuma disponível" - -#: conf/admin_templates/admin_object_history.html:4 -#: conf/admin_templates/base.html:28 -#: conf/admin_templates/registration/password_reset_form.html:3 -#: conf/admin_templates/registration/logged_out.html:3 -#: conf/admin_templates/registration/password_reset_done.html:3 -#: conf/admin_templates/registration/password_change_form.html:3 -#: conf/admin_templates/registration/password_change_done.html:3 -msgid "Home" -msgstr "Início" - -#: conf/admin_templates/admin_object_history.html:4 -msgid "History" -msgstr "Histórico" - -#: conf/admin_templates/admin_object_history.html:17 -msgid "Date/time" -msgstr "Data/hora" - -#: conf/admin_templates/admin_object_history.html:18 -msgid "User" -msgstr "Usuário" - -#: conf/admin_templates/admin_object_history.html:19 -msgid "Action" -msgstr "Ação" - -#: conf/admin_templates/admin_object_history.html:35 -msgid "" -"This object doesn't have a change history. It probably wasn't added via this " -"admin site." -msgstr "" -"Este objeto não tem um histórico de alterações. Ele provavelmente não foi " -"adicionado por este site de administração." - -#: conf/admin_templates/base_site.html:3 -msgid "Django site admin" -msgstr "Site de administração do Django" - -#: conf/admin_templates/base_site.html:6 -msgid "Django administration" -msgstr "Administração do Django" - -#: conf/admin_templates/500.html:5 -msgid "Server error (500)" -msgstr "Erro no servidor (500)" - -#: conf/admin_templates/500.html:8 -msgid "Server Error (500)" -msgstr "Erro no Servidor (500)" - -#: conf/admin_templates/500.html:9 -msgid "" -"There's been an error. It's been reported to the site administrators via e-" -"mail and should be fixed shortly. Thanks for your patience." -msgstr "" -"Houve um erro. Este foi reportado aos administradores do site através d " -"e-mail e deve ser consertado em breve. Obrigado pela compreensão." - -#: conf/admin_templates/delete_confirmation_generic.html:6 -#, python-format -msgid "" -"Deleting the %(object_name)s '%(object)s' would result in deleting related " -"objects, but your account doesn't have permission to delete the following " -"types of objects:" -msgstr "" -"A remoção de '%(object)s' %(object_name)s pode resultar na remoção de " -"objetos relacionados, mas sua conta não tem a permissão para remoção dos " -"seguintes tipos de objetos:" - -#: conf/admin_templates/delete_confirmation_generic.html:13 -#, python-format -msgid "" -"Are you sure you want to delete the %(object_name)s \"%(object)s\"? All of " -"the following related items will be deleted:" -msgstr "" -"Você tem certeza que quer remover o \"%(object)s\" %(object_name)s? Todos " -"os seguintes itens relacionados serão removidos:" - -#: conf/admin_templates/delete_confirmation_generic.html:17 -msgid "Yes, I'm sure" -msgstr "Sim, tenho certeza" - -#: conf/admin_templates/changelist_generic.html:26 -msgid "Click to change" -msgstr "Clique para alterar" - -#: conf/admin_templates/login.html:14 -msgid "Username:" -msgstr "Usuário:" - -#: conf/admin_templates/login.html:17 -msgid "Password:" -msgstr "Senha:" - -#: conf/admin_templates/login.html:19 -msgid "Have you forgotten your password?" -msgstr "Você ?" - -#: conf/admin_templates/login.html:23 -msgid "Log in" -msgstr "Acessar" - -#: conf/admin_templates/base.html:22 -msgid "Welcome," -msgstr "Bem vindo," - -#: conf/admin_templates/base.html:22 -msgid "Change password" -msgstr "Alterar senha" - -#: conf/admin_templates/base.html:22 -msgid "Log out" -msgstr "Encerrar sessão" - -#: conf/admin_templates/registration/password_reset_form.html:3 -#: conf/admin_templates/registration/password_reset_form.html:5 -#: conf/admin_templates/registration/password_reset_form.html:9 -#: conf/admin_templates/registration/password_reset_done.html:3 -msgid "Password reset" -msgstr "Reinicializar senha" - -#: conf/admin_templates/registration/password_reset_form.html:11 -msgid "" -"Forgotten your password? Enter your e-mail address below, and we'll reset " -"your password and e-mail the new one to you." -msgstr "" -"Esqueceu a senha? Digite seu e-mail abaixo e nós iremos enviar uma nova " -"senha para você." - -#: conf/admin_templates/registration/password_reset_form.html:15 -msgid "E-mail address:" -msgstr "Endereço de e-mail:" - -#: conf/admin_templates/registration/password_reset_form.html:15 -msgid "Reset my password" -msgstr "Reinicializar minha senha" - -#: conf/admin_templates/registration/password_reset_email.html:1 -msgid "You're receiving this e-mail because you requested a password reset" -msgstr "Você está recebendo este e-mail porque você pediu uma nova senha" - -#: conf/admin_templates/registration/password_reset_email.html:2 -#, python-format -msgid "for your user account at %(site_name)s" -msgstr "para sua conta em %(site_name)s" - -#: conf/admin_templates/registration/password_reset_email.html:4 -#, python-format -msgid "Your new password is: %(new_password)s" -msgstr "Sua nova senha é: %(new_password)s" - -#: conf/admin_templates/registration/password_reset_email.html:6 -msgid "Feel free to change this password by going to this page:" -msgstr "Sinta-se livre para alterar esta senha visitando esta página:" - -#: conf/admin_templates/registration/password_reset_email.html:10 -msgid "Your username, in case you've forgotten:" -msgstr "Seu nome de usuário, caso tenha esquecido:" - -#: conf/admin_templates/registration/password_reset_email.html:12 -msgid "Thanks for using our site!" -msgstr "Obrigado por usar nosso site!" - -#: conf/admin_templates/registration/password_reset_email.html:14 -#, python-format -msgid "The %(site_name)s team" -msgstr "Time do %(site_name)s" - -#: conf/admin_templates/registration/logged_out.html:7 -msgid "Thanks for spending some quality time with the Web site today." -msgstr "Obrigado por visitar nosso Web site hoje." - -#: conf/admin_templates/registration/logged_out.html:9 -msgid "Log in again" -msgstr "Acessar novamente" - -#: conf/admin_templates/registration/password_reset_done.html:5 -#: conf/admin_templates/registration/password_reset_done.html:9 -msgid "Password reset successful" -msgstr "Senha inicializada com sucesso" - -#: conf/admin_templates/registration/password_reset_done.html:11 -msgid "" -"We've e-mailed a new password to the e-mail address you submitted. You " -"should be receiving it shortly." -msgstr "" -"Nós enviamos uma nova senha para o e-mail que você informou. Você deve " -"estar recebendo uma mensagem em breve." - -#: conf/admin_templates/registration/password_change_form.html:3 -#: conf/admin_templates/registration/password_change_form.html:5 -#: conf/admin_templates/registration/password_change_form.html:9 -#: conf/admin_templates/registration/password_change_done.html:3 -msgid "Password change" -msgstr "Alterar senha" - -#: conf/admin_templates/registration/password_change_form.html:11 -msgid "" -"Please enter your old password, for security's sake, and then enter your new " -"password twice so we can verify you typed it in correctly." -msgstr "" -"Por favor, informe sua senha antiga, por segurança, e então informe sua nova " -"senha duas vezes para que possamos verificar que se ela está correta." - -#: conf/admin_templates/registration/password_change_form.html:16 -msgid "Old password:" -msgstr "Senha antiga:" - -#: conf/admin_templates/registration/password_change_form.html:18 -msgid "New password:" -msgstr "Nova senha:" - -#: conf/admin_templates/registration/password_change_form.html:20 -msgid "Confirm password:" -msgstr "Confirme a senha:" - -#: conf/admin_templates/registration/password_change_form.html:22 -msgid "Change my password" -msgstr "Alterar minha senha" - -#: conf/admin_templates/registration/password_change_done.html:5 -#: conf/admin_templates/registration/password_change_done.html:9 -msgid "Password change successful" -msgstr "Senha alterada com sucesso" - -#: conf/admin_templates/registration/password_change_done.html:11 -msgid "Your password was changed." -msgstr "Sua senha foi alterada." - -#: core/validators.py:56 -msgid "This value must contain only letters, numbers and underscores." -msgstr "Deve conter apenas letras, números e sublinhados (_)." diff --git a/django/conf/locale/pt_BR/LC_MESSAGES/django.mo b/django/conf/locale/pt_BR/LC_MESSAGES/django.mo new file mode 100644 index 0000000000..395b7554e3 Binary files /dev/null and b/django/conf/locale/pt_BR/LC_MESSAGES/django.mo differ diff --git a/django/conf/locale/pt_BR/LC_MESSAGES/django.po b/django/conf/locale/pt_BR/LC_MESSAGES/django.po new file mode 100644 index 0000000000..c005bb39d8 --- /dev/null +++ b/django/conf/locale/pt_BR/LC_MESSAGES/django.po @@ -0,0 +1,283 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR , YEAR. +# +#, fuzzy +msgid "" +msgstr "" +"Project-Id-Version: django\n" +"Report-Msgid-Bugs-To: jpaulofarias@gmail.com\n" +"POT-Creation-Date: 2005-10-11 09:11-0300\n" +"PO-Revision-Date: 2005-10-11 09:12GMT-3\n" +"Last-Translator: João Paulo Farias \n" +"Language-Team: Português do Brasil \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" + +#: conf/admin_templates/404.html:3 conf/admin_templates/404.html.py:7 +msgid "Page not found" +msgstr "Página não encontrada" + +#: conf/admin_templates/404.html:9 +msgid "We're sorry, but the requested page could not be found." +msgstr "Desculpe, mas a página requisitada não pode ser encontrada." + +#: conf/admin_templates/index.html:26 +#: conf/admin_templates/changelist_generic.html:8 +msgid "Add" +msgstr "Adicionar" + +#: conf/admin_templates/index.html:32 +msgid "Change" +msgstr "Modificar" + +#: conf/admin_templates/index.html:42 +msgid "You don't have permission to edit anything." +msgstr "Você não tem permissão para edição." + +#: conf/admin_templates/index.html:50 +msgid "Recent Actions" +msgstr "Ações Recentes" + +#: conf/admin_templates/index.html:51 +msgid "My Actions" +msgstr "Minhas Ações" + +#: conf/admin_templates/index.html:55 +msgid "None available" +msgstr "Nenhuma disponível" + +#: conf/admin_templates/admin_object_history.html:4 +#: conf/admin_templates/base.html:28 +#: conf/admin_templates/registration/password_reset_form.html:3 +#: conf/admin_templates/registration/logged_out.html:3 +#: conf/admin_templates/registration/password_reset_done.html:3 +#: conf/admin_templates/registration/password_change_form.html:3 +#: conf/admin_templates/registration/password_change_done.html:3 +msgid "Home" +msgstr "Início" + +#: conf/admin_templates/admin_object_history.html:4 +msgid "History" +msgstr "Histórico" + +#: conf/admin_templates/admin_object_history.html:17 +msgid "Date/time" +msgstr "Data/hora" + +#: conf/admin_templates/admin_object_history.html:18 +msgid "User" +msgstr "Usuário" + +#: conf/admin_templates/admin_object_history.html:19 +msgid "Action" +msgstr "Ação" + +#: conf/admin_templates/admin_object_history.html:35 +msgid "" +"This object doesn't have a change history. It probably wasn't added via this " +"admin site." +msgstr "" +"Este objeto não tem um histórico de alterações. Ele provavelmente não foi " +"adicionado por este site de administração." + +#: conf/admin_templates/base_site.html:3 +msgid "Django site admin" +msgstr "Site de administração do Django" + +#: conf/admin_templates/base_site.html:6 +msgid "Django administration" +msgstr "Administração do Django" + +#: conf/admin_templates/500.html:5 +msgid "Server error (500)" +msgstr "Erro no servidor (500)" + +#: conf/admin_templates/500.html:8 +msgid "Server Error (500)" +msgstr "Erro no Servidor (500)" + +#: conf/admin_templates/500.html:9 +msgid "" +"There's been an error. It's been reported to the site administrators via e-" +"mail and should be fixed shortly. Thanks for your patience." +msgstr "" +"Houve um erro. Este foi reportado aos administradores do site através d " +"e-mail e deve ser consertado em breve. Obrigado pela compreensão." + +#: conf/admin_templates/delete_confirmation_generic.html:6 +#, python-format +msgid "" +"Deleting the %(object_name)s '%(object)s' would result in deleting related " +"objects, but your account doesn't have permission to delete the following " +"types of objects:" +msgstr "" +"A remoção de '%(object)s' %(object_name)s pode resultar na remoção de " +"objetos relacionados, mas sua conta não tem a permissão para remoção dos " +"seguintes tipos de objetos:" + +#: conf/admin_templates/delete_confirmation_generic.html:13 +#, python-format +msgid "" +"Are you sure you want to delete the %(object_name)s \"%(object)s\"? All of " +"the following related items will be deleted:" +msgstr "" +"Você tem certeza que quer remover o \"%(object)s\" %(object_name)s? Todos " +"os seguintes itens relacionados serão removidos:" + +#: conf/admin_templates/delete_confirmation_generic.html:17 +msgid "Yes, I'm sure" +msgstr "Sim, tenho certeza" + +#: conf/admin_templates/changelist_generic.html:26 +msgid "Click to change" +msgstr "Clique para alterar" + +#: conf/admin_templates/login.html:14 +msgid "Username:" +msgstr "Usuário:" + +#: conf/admin_templates/login.html:17 +msgid "Password:" +msgstr "Senha:" + +#: conf/admin_templates/login.html:19 +msgid "Have you forgotten your password?" +msgstr "Você ?" + +#: conf/admin_templates/login.html:23 +msgid "Log in" +msgstr "Acessar" + +#: conf/admin_templates/base.html:22 +msgid "Welcome," +msgstr "Bem vindo," + +#: conf/admin_templates/base.html:22 +msgid "Change password" +msgstr "Alterar senha" + +#: conf/admin_templates/base.html:22 +msgid "Log out" +msgstr "Encerrar sessão" + +#: conf/admin_templates/registration/password_reset_form.html:3 +#: conf/admin_templates/registration/password_reset_form.html:5 +#: conf/admin_templates/registration/password_reset_form.html:9 +#: conf/admin_templates/registration/password_reset_done.html:3 +msgid "Password reset" +msgstr "Reinicializar senha" + +#: conf/admin_templates/registration/password_reset_form.html:11 +msgid "" +"Forgotten your password? Enter your e-mail address below, and we'll reset " +"your password and e-mail the new one to you." +msgstr "" +"Esqueceu a senha? Digite seu e-mail abaixo e nós iremos enviar uma nova " +"senha para você." + +#: conf/admin_templates/registration/password_reset_form.html:15 +msgid "E-mail address:" +msgstr "Endereço de e-mail:" + +#: conf/admin_templates/registration/password_reset_form.html:15 +msgid "Reset my password" +msgstr "Reinicializar minha senha" + +#: conf/admin_templates/registration/password_reset_email.html:1 +msgid "You're receiving this e-mail because you requested a password reset" +msgstr "Você está recebendo este e-mail porque você pediu uma nova senha" + +#: conf/admin_templates/registration/password_reset_email.html:2 +#, python-format +msgid "for your user account at %(site_name)s" +msgstr "para sua conta em %(site_name)s" + +#: conf/admin_templates/registration/password_reset_email.html:4 +#, python-format +msgid "Your new password is: %(new_password)s" +msgstr "Sua nova senha é: %(new_password)s" + +#: conf/admin_templates/registration/password_reset_email.html:6 +msgid "Feel free to change this password by going to this page:" +msgstr "Sinta-se livre para alterar esta senha visitando esta página:" + +#: conf/admin_templates/registration/password_reset_email.html:10 +msgid "Your username, in case you've forgotten:" +msgstr "Seu nome de usuário, caso tenha esquecido:" + +#: conf/admin_templates/registration/password_reset_email.html:12 +msgid "Thanks for using our site!" +msgstr "Obrigado por usar nosso site!" + +#: conf/admin_templates/registration/password_reset_email.html:14 +#, python-format +msgid "The %(site_name)s team" +msgstr "Time do %(site_name)s" + +#: conf/admin_templates/registration/logged_out.html:7 +msgid "Thanks for spending some quality time with the Web site today." +msgstr "Obrigado por visitar nosso Web site hoje." + +#: conf/admin_templates/registration/logged_out.html:9 +msgid "Log in again" +msgstr "Acessar novamente" + +#: conf/admin_templates/registration/password_reset_done.html:5 +#: conf/admin_templates/registration/password_reset_done.html:9 +msgid "Password reset successful" +msgstr "Senha inicializada com sucesso" + +#: conf/admin_templates/registration/password_reset_done.html:11 +msgid "" +"We've e-mailed a new password to the e-mail address you submitted. You " +"should be receiving it shortly." +msgstr "" +"Nós enviamos uma nova senha para o e-mail que você informou. Você deve " +"estar recebendo uma mensagem em breve." + +#: conf/admin_templates/registration/password_change_form.html:3 +#: conf/admin_templates/registration/password_change_form.html:5 +#: conf/admin_templates/registration/password_change_form.html:9 +#: conf/admin_templates/registration/password_change_done.html:3 +msgid "Password change" +msgstr "Alterar senha" + +#: conf/admin_templates/registration/password_change_form.html:11 +msgid "" +"Please enter your old password, for security's sake, and then enter your new " +"password twice so we can verify you typed it in correctly." +msgstr "" +"Por favor, informe sua senha antiga, por segurança, e então informe sua nova " +"senha duas vezes para que possamos verificar que se ela está correta." + +#: conf/admin_templates/registration/password_change_form.html:16 +msgid "Old password:" +msgstr "Senha antiga:" + +#: conf/admin_templates/registration/password_change_form.html:18 +msgid "New password:" +msgstr "Nova senha:" + +#: conf/admin_templates/registration/password_change_form.html:20 +msgid "Confirm password:" +msgstr "Confirme a senha:" + +#: conf/admin_templates/registration/password_change_form.html:22 +msgid "Change my password" +msgstr "Alterar minha senha" + +#: conf/admin_templates/registration/password_change_done.html:5 +#: conf/admin_templates/registration/password_change_done.html:9 +msgid "Password change successful" +msgstr "Senha alterada com sucesso" + +#: conf/admin_templates/registration/password_change_done.html:11 +msgid "Your password was changed." +msgstr "Sua senha foi alterada." + +#: core/validators.py:56 +msgid "This value must contain only letters, numbers and underscores." +msgstr "Deve conter apenas letras, números e sublinhados (_)." diff --git a/django/utils/translation.py b/django/utils/translation.py index 96c98f691a..0ffd4a2e43 100644 --- a/django/utils/translation.py +++ b/django/utils/translation.py @@ -271,6 +271,9 @@ def get_language_from_request(request): else: lang = el order = 100 + if lang.find('-') >= 0: + (lang, sublang) = lang.split('-') + lang = lang.lower() + '_' + sublang.upper() return (lang, order) langs = [_parsed(el) for el in accept.split(',')] @@ -279,14 +282,9 @@ def get_language_from_request(request): globalpath = os.path.join(os.path.dirname(settings.__file__), 'locale') for lang, order in langs: - if lang == 'en' or os.path.isfile(os.path.join(globalpath, lang, 'LC_MESSAGES', 'django.mo')): + if lang == 'en' or lang.startswith('en_') or gettext_module.find('django', globalpath, [lang]): _accepted[accept] = lang return lang - elif lang.find('-') >= 0: - (lang, sublang) = lang.split('-', 1) - if lang == 'en' or os.path.isfile(os.path.join(globalpath, lang, 'LC_MESSAGES', 'django.mo')): - _accepted[accept] = lang - return lang return settings.LANGUAGE_CODE diff --git a/docs/translation.txt b/docs/translation.txt index 2a95286e0e..37d2bc2385 100644 --- a/docs/translation.txt +++ b/docs/translation.txt @@ -179,11 +179,18 @@ If neither GET nor POST have django_language, the middleware looks at the session data for the user. If that carries a key django_language, it's contents will be used as the language code. If the session doesn't contain a language setting, the middleware will look at the cookies for a django_language cookie. -If that is found, it gives the language code. If neither the session nor the -cookie carry a language code, the middleware will look at the HTTP header -Accept-Language. This header is sent by your browser and tells the server what -languages you prefer. Languages are ordered by some choice value - the higher, -the more you prefer the language. +If that is found, it gives the language code. + +The format for the explicit django_language parameters is allways the +locale to use - for example it's pt_BR for Brazilian. If a base language +is available, but the sublanguage specified is not, the base language is used. +For example if you specify de_AT (Austrian German), but there is only a +language de available, that language is used. + +If neither the session nor the cookie carry a language code, the middleware +will look at the HTTP header Accept-Language. This header is sent by your +browser and tells the server what languages you prefer. Languages are ordered +by some choice value - the higher, the more you prefer the language. So the middleware will iterate over that header, ordered by the preference value. The language with the highest preference that is in the django base @@ -231,6 +238,9 @@ might be that it is utf-8 - if you prefer another encoding, you can use some tools like recode or iconv to change the charset of the file and then change the charset definition in the file (it's in the Content-Type: line). +The language code for storage is in locale format - so it is pt_BR for +Brazilian or de_AT for Austrian German. + Every message in the message file is of the same format. One line is the msgid. This is the actual string in the source - you don't change it. The other line is msgstr - this is the translation. It starts out empty. You change it. -- cgit v1.3