#11585: i18n in urls.py
---------------------------+------------------------------------------------
Reporter: digi604 | Owner: nobody
Status: new | Milestone: 1.2
Component: Uncategorized | Version: SVN
Keywords: | Stage: Unreviewed
Has_patch: 0 |
---------------------------+------------------------------------------------
Because search engines not only search in english we normally "translate"
the urls as well to get higher pageranks in the sites languages.
This is very cumbersome at the moment with django.
example:
en: /contact/
de: /kontakt/
it: /contatto/
they all point to the same view.
it would be nice to have a i18n_url() that would resolve based on the
current language.
{{{
i18n_url({'de':r'^kontakt/', 'en':r'^contact/', 'it':r'^contatto/'},
contact, name="contact"}
}}}
it would be nice to be able to tell reverse() and {% url %} which language
to resolve.
{{{
{% url contact de %}
reverse('contact', language="de")
}}}
If no language is defined it should take the current one from
get_language()
--
Ticket URL: <http://code.djangoproject.com/ticket/11585>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---