Op 2015-03-03T17:41:21 UTC schreef Jaap van Wingerde
<mailinglists@vanwingerde.nl> in the message <how to deal with not
translated strings in html>,
mid:20150303174121.024af2be@jaap.custard.shrl.nl the following text.
> ../locale/en/LC_MESSAGES/django.po:
>
> ...
> #: template.html:4
> msgid "jaar"
> msgstr "year"
>
> #: templates.html:4
> msgid "maand"
> msgstr ""
> ...
>
> ../templates/template.html:
>
> {% load i18n %}<!DOCTYPE html><html
> lang="{{ LANGUAGE_CODE }}">
> ...
> {% trans "jaar" %}<br />{% trans "maand" %}
> ...
>
> resulting html:
>
> <!DOCTYPE html><html
> lang="en">
> ...
> year<br />maand
> ...
>
> better html:
>
> <!DOCTYPE html><html
> lang="en">
> ...
> year<br /><span lang="nl">maand</span>
> ...
>
> How can i get the better html?
A solution with handwork:
#: templates.html:4
msgid "maand"
msgstr "<span lang="nl">maand</span>"
Can this be done automagical?
--
Jaap van Wingerde
e-mail: 1234567890@vanwingerde.nl
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/20150304145226.0615f5ff%40jaap.custard.shrl.nl.
For more options, visit https://groups.google.com/d/optout.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment