On Monday, July 4, 2011 1:42:37 AM UTC+12, brocaar wrote: > > What about not implementing this as a url tag but as a translation- > override tag? Then it is not only possible to specify the language to > use for your URL translation, but as well for other translatable > content. Example: > > {% transoverride language_code %} > {% trans "Register account" %}: {% url account:register %} > {% endtransoverride %} > > That does have the advantage of being more flexible even in just the context of urls. For example, referring to a url via {{ obj.get_absolute_url }}. +1 for more flexibility.
That's one ugly tag name though :D -- You received this message because you are subscribed to the Google Groups "Django developers" group. To view this discussion on the web visit https://groups.google.com/d/msg/django-developers/-/F-ICvrsxqqMJ. To post to this group, send email to django-developers@googlegroups.com. To unsubscribe from this group, send email to django-developers+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-developers?hl=en.