Expected behaviour would be that a newly visiting person with FR as first setting in HTTP header should see the french version of the page (which is existing and set as language in settings, but not as default. manual language switch is working).

Accoriding to django docs language should be determined in the following order

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

  1. language prefix in the requested URL
  2. cookie
  3. Accept-Language HTTP header
  4. Default Settings

Actual behaviour correctly switches navigation nodes (django cms menu) to french, but not cms plugin content (displayed in default language).

#MIDDLEWARE SETTINGS (order as mentioned in docs)

'cms.middleware.utils.ApphookReloadMiddleware',
'whitenoise.middleware.WhiteNoiseMiddleware',
'webpack.middleware.WebpackDevserverMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.contrib.admindocs.middleware.XViewMiddleware',
'django.middleware.locale.LocaleMiddleware',
'django.middleware.common.CommonMiddleware',
'cms.middleware.page.CurrentPageMiddleware',
'cms.middleware.user.CurrentUserMiddleware',
'cms.middleware.toolbar.ToolbarMiddleware',
'cms.middleware.language.LanguageCookieMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',

##################################################################
# multisite language handling
##################################################################
AVAILABLE_LANGUAGES = {
    'de': _('Deutsch'),
    'fr': _('Französisch'),
    'it': _('Italiano'),
    'en': _('English'),
}
SITE_LANGUAGES = config('SITE_LANGUAGES', default='de,fr', cast=Csv())
LANGUAGE_CODE = SITE_LANGUAGES[0]
LANGUAGES = [(k, v) for k, v in AVAILABLE_LANGUAGES.items() if k in SITE_LANGUAGES]

Is CMS_LANGUAGES needed if SITE_LANGUAGES are set. In Django CMS all relevant options in page tree are available. I could not see any different behaviour if set.

Any ideas what could cause this behaviour?

0 Answers