Opened 5 years ago
Last modified 5 years ago
#32533 closed Uncategorized
i18n l10n set the Accept-Language but always get settings.LANGUAGE_CODE — at Version 3
| Reported by: | iwmbm | Owned by: | nobody |
|---|---|---|---|
| Component: | Uncategorized | Version: | 3.1 |
| Severity: | Normal | Keywords: | i18n, l10n |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | no | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | no |
| Easy pickings: | no | UI/UX: | no |
Description (last modified by )
Hello, everyone!
settings.py
LANGUAGE_CODE = 'zh-hant'
MIDDLEWARE = [
...
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.locale.LocaleMiddleware',
'django.middleware.common.CommonMiddleware',
...
]
browser request headers
Accept-Language:Accept-Language: en,en-US;q=0.9,de;q=0.8
i try to get request.LANGUAGE_CODE but always return zh-hant
Change History (3)
comment:1 by , 5 years ago
| Description: | modified (diff) |
|---|
comment:2 by , 5 years ago
| Description: | modified (diff) |
|---|
comment:3 by , 5 years ago
| Description: | modified (diff) |
|---|
Note:
See TracTickets
for help on using tickets.