Skip to content

Loading…

[docs] extended i18n page language detection #2752

Merged
merged 1 commit into from

3 participants

@Chive
Divio AG member

Fixes issue 9 of #2150

@Chive Chive referenced this pull request
Closed

(doc) Misc issues about 3.0 #2150

@coveralls

Coverage Status

Coverage remained the same when pulling c3e77c3 on Chive:docs/i18n into 3a09d5c on divio:develop.

@digi604 digi604 merged commit af4725e into divio:develop

1 check passed

Details default The Travis CI build passed
@Chive Chive deleted the unknown repository branch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Feb 27, 2014
  1. @Chive
This page is out of date. Refresh to see the latest.
Showing with 5 additions and 0 deletions.
  1. +5 −0 docs/advanced/i18n.rst
View
5 docs/advanced/i18n.rst
@@ -39,6 +39,8 @@ Main `urls.py` example::
Language Cookie
***************
+If a user comes back to a previously visited page, the language will be same since his last visit.
+
By default if someone visits a page at `http://www.mysite.fr/` django determines the language as follow:
- language in url
@@ -47,6 +49,9 @@ By default if someone visits a page at `http://www.mysite.fr/` django determines
- language in from browser
- LANGUAGE_CODE from settings
+More in-depth documentation about this is available at
+https://docs.djangoproject.com/en/dev/topics/i18n/translation/#how-django-discovers-language-preference
+
When visiting a page that is only English and French with a German browser, the language from LANGUAGE_CODE will be used.
If this is English, but the visitor only speaks French, the visitor will have to switch the language.
Visiting the same page now again after some time, will show it in English again, because the browser session which was
Something went wrong with that request. Please try again.