2007/4/5, Malcolm Tredinnick <[EMAIL PROTECTED]>: [...] > In [1]: from django.utils.translation import activate, gettext > > In [2]: gettext("The %(verbose_name)s was created successfully.") % > {"verbose_name": "xyzzy"} > Out[2]: 'The xyzzy was created successfully.' > > In [3]: activate('es') > > In [4]: gettext("The %(verbose_name)s was created successfully.") % > {"verbose_name": "xyzzy"} > Out[4]: 'El xyzzy se ha creado correctamente.' > > In [5]: activate('de') > In [6]: gettext("The %(verbose_name)s was created successfully.") % > {"verbose_name": "xyzzy"} > Out[6]: 'xyzzy wurde erfolgreich angelegt.' > > In particular, what happens when you use activate() for your preferred > locale and then run the gettext() test?
I found it works with the locale "es" but not with the "es_AR". The only difference i find about that specific translation in the .po's is that es_AR has accented characters and es has not: es: #: views/generic/create_update.py:43 #, python-format msgid "The %(verbose_name)s was created successfully." msgstr "El %(verbose_name)s se ha creado correctamente." es_AR: #: views/generic/create_update.py:43 #, python-format msgid "The %(verbose_name)s was created successfully." msgstr "Se creó con éxito %(verbose_name)." When I changed LANGUAGE_CODE to es instead of es_AR it worked fine but es_AR will probably fail if i use create_update.update_object() because the translation for a successfull update has accented characters. Are the accented chars the problem? Maybe it is related with the problem reported in the email with Subject: svn trunk broken since [4919], encoding problems. Regards. -- Marcelo Ramos Fedora Core 6 | 2.6.19 Socio UYLUG Nro 125 --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---