[Solved]-404 on requests without trailing slash to i18n urls

20👍

it doesn’t work properly if the middleware’s aren’t in order.

see:
https://docs.djangoproject.com/en/1.5/topics/i18n/translation/#how-django-discovers-language-preference

that’s how it should look like:

MIDDLEWARE_CLASSES = (
   'django.contrib.sessions.middleware.SessionMiddleware',
   'django.middleware.locale.LocaleMiddleware',
   'django.middleware.common.CommonMiddleware',
   ...
)
👤fetzig

Leave a comment