A section's background image is not published to Live site when using Content Pages with Staging
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
- A section's background image is not published to the Live site when using Content Pages with Staging
-
Steps to Reproduce:
1) Enable Staging on the target site
2) Check the Group ID of the site in Site Settings, and make note of it (e.g. 34378)
3) Add a new public page with Content Page type
4) Edit the Content Page
5) On the right-hand panel, select Section Builder (the second icon)
6) Click the Layouts dropdown, and drag the first (1 column) layout onto the page
7) Click on the newly added section and click on the Layout Background Image icon (the second contextual icon)
8) Click the Select button, and select an image file to add as the background. Once completed, click Add.
9) Inspect that Section, and make note of the URL and groupId (e.g. 37061):
box-sizing: border-box;background-position: 50% 50%; background-repeat: no-repeat; background-size: cover; background-image: url(/documents/37061/0/sample.png/e30dcdfb-87f2-dcc0-b5e1-8b82bd6be46a?t=1600062453164&download=true);border-style: solid; border-width: 0px;opacity: 1.0;
10) Publish the Content Page
11) Revisit the Content Page, then Publish the page from Staging to Live
12) Check the Live version of that page, and inspect the Section, and make note of the URL and groupId:
box-sizing: border-box;background-position: 50% 50%; background-repeat: no-repeat; background-size: cover; background-image: url(/documents/37061/0/sample.png/e30dcdfb-87f2-dcc0-b5e1-8b82bd6be46a?t=1600062453164&download=true);border-style: solid; border-width: 0px;opacity: 1.0;
Actual Behavior: Background image is using the Staged version (i.e., group ID: 37061) as opposed to the Live site's version (i.e., group ID: 34378)
Expected Behavior: The background image should have been promoted to the Live site and should be used by the live site's layout section.
Environment
- Liferay DXP 7.2
- Liferay DXP 7.3
Resolution
- The observed behavior is a known bug. It is fixed in fix-pack-dxp-9 for Liferay 7.2 and fix-pack-dxp-1 for Liferay 7.3
- If the hotfix is required for this issue, please create a support ticket requesting the hotfix by attaching the patch details.
-
Installing Fix Packs and Hotfixes on Liferay DXP will guide you to install the Fixpack/Hotfix in your environment.
Did this article resolve your issue ?