Legacy Knowledge Base
Published Jul. 2, 2025

Content Page image lost after changing site's default language

Written By

Rita Schaff

How To articles are not official guidelines or officially supported documentation. They are community-contributed content and may not always reflect the latest updates to Liferay DXP. We welcome your feedback to improve How To articles!

While we make every effort to ensure this Knowledge Base is accurate, it may not always reflect the most recent updates or official guidelines.We appreciate your understanding and encourage you to reach out with any feedback or concerns.

Legacy Article

You are viewing an article from our legacy "FastTrack" publication program, made available for informational purposes. Articles in this program were published without a requirement for independent editing or verification and are provided"as is" without guarantee.

Before using any information from this article, independently verify its suitability for your situation and project.

Issue

  • After changing the default language on a site and checking content fragments that include images, the content on existing pages is not displayed anymore if we change the translation.

Environment

  • DXP 7.2
  • DXP 7.3

Resolution

  • This is the expected default behavior because every localized content (like Content Pages in this case) in Liferay works in the following way: 

    1. Given a requested language, if the content is translated to the requested language, the content is displayed in the requested language.
    2. Given a requested language, if the content is not translated to the requested language, and the content is translated to the site's default language, the content is displayed in the site's default language.
    3. Given a requested language, if the content is not translated to the requested language, and the content is not translated to the site's default language, the content is not displayed.

    Given the above 3 scenarios and the resulting behavior:

    • The Content Page only has a translation for German
    • The site's default language is English
    • The requested language is German→scenario #1 applies
    • The requested language is English→scenario #2 applies
    • The requested language is Spanish→scenario #3 applies

Additional Information 

  • Changing the default language of the site also gives a warning about this: "This change will only affect the newly created localized content."
    If the aim is to have English as the site default language and the image to be present in all untranslated languages, the image must be present on the Content Page's English translation.
  • We have a feature request for this that you can view here: LPS-142787
    We encourage you to click on the "Start watching this issue" option to track the request for updates, and vote for it or share your thoughts in the comment section.
Did this article resolve your issue ?

Legacy Knowledge Base