If options for content language detection are enabled but content language detection is disabled those options still have an effect

Created on 19 July 2025, about 2 months ago

Problem/Motivation

On admin/config/regional/language/detection if you keep some of the options enabled within the content language detection section and then disable the Customize Content language detection to differ from Interface text language detection settings checkbox, those options still are active and have an effect on which content is displayed on pages.

Steps to reproduce

  • Enable the language and content translation module
  • Add a second language aside english
  • Leave english as the default langauge
  • tick Account administration pages in the interface text language detection section on admin/config/regional/language/detection
  • on user/1/edit within the language settings set both select components to english
  • on admin/config/regional/content-language enable custom language settings for media and make image translatable and save
  • on admin/content/media add a media item in english
  • after creating click the drop button and choose the translate option and then add a translation for the other language you added so each available language for the media item has a translation
  • if you revisit the media item you just translated it will show the english version instead of the translated version
  • go to admin/config/regional/language/detection tick the Customize Content language detection to differ from Interface text language detection settings checkbox and enable the content language and URL checkbox
  • revisit the translated media item => the interface language is still english but the translated media item is now correctly displayed
  • go to admin/config/regional/language/detection leave the content language and URL checkboxes enabled but uncheck Customize Content language detection to differ from Interface text language detection settings so the content language table detection table is hidden and save
  • revisit the translated media item => the interface is still english and the content is showing the correct translated strings which is unexpected cuz you basically disabled content language detection

Proposed resolution

If the Customize Content language detection to differ from Interface text language detection settings checkbox is unchecked any option within the content language detection table that is enabled should have no effect and treated as disabled as long as Customize Content language detection to differ from Interface text language detection settings is unchecked.

Remaining tasks

User interface changes

Introduced terminology

API changes

Data model changes

Release notes snippet

🐛 Bug report
Status

Active

Version

11.0 🔥

Component

language system

Created by

🇩🇪Germany rkoller Nürnberg, Germany

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024