2

I am using Sitecore 9.2 with SXA 1.9.

My experience with using the out of the box sxa layout is that three placeholders are present: header, main, and footer.

sxa layout with page design rendering content into body placeholder

About a week ago we began to see a fourth placeholder: body_top. In addition to this, all page designs now fail to render content into the main placeholder.

sxa layout where body_top placeholder is visible and page designs fail to render

I initially thought that this might be related to the theme based on the following blog post: http://blog.martinmiles.net/post/mythical-sxa-body-top-placeholder. I have a backup instance of the master db with the same tenant from a week prior in which all page designs on all sites across the tenant work as expected. I overwrote the theme on the non-working Sitecore instance, but this did not help.

I swapped the non-working master-db into the working Sitecore instance, thinking it might be custom code-related. This was unsuccessful (body_top present, and page designs fail to render in main placeholder). This led me to believe that it must be configuration-based.

I was able to create a new tenant as a sibling of the non-working tenant using the same theme, and these sites worked (i.e. did not have the body_top placeholder and page designs were rendering in the main placeholder). Copying a site out of the non-working tenant into the working tenant (and updating all of the settings, as well as re-templating to the working tenant's templates) was unsuccessful. Likewise, copying a working site into the non-working tenant was also unsuccessful.

I have seen several posts about incorrect configuration of site groupings, as well as site entries in the config. I have double-triple checked these, and neither of them are the issue in my case.

I have validated that all of the configuration settings (that I know to check) are the same between the week old copy of the tenant in its working state, and the current non-working version. Tenant-level theme, form, and media folders, as well as modules. Site-level modules, editing theme, allowed themes, component theme, and default theme.

Viewing the experience editor debug output shows that the SXA PartialDesign Dynamic Placeholder is not being rendered into the appropriate placeholders on the non-working tenant sites.

Non-working page debug output: Non-working debug output

Working page debug output: enter image description here

I am seeing debug statements associated with page loads like below. There are many of these, with guids corresponding to SXA components like sticky notes. Some are unidentifiable guids. The guid in the debug statement below corresponds to the SXA PartialDesign Dynamic Placeholder. Not sure what it is implying.

11656 15:59:46 DEBUG [Sitecore Mvc]: Area resolution starting

11656 15:59:46 DEBUG [Sitecore Mvc]: Area resolution (RenderingDefinitionAreaResolveStrategy) returned NULL

11656 15:59:46 DEBUG [Sitecore Mvc]: Area resolution (RenderingParametersAreaResolveStrategy) returned NULL

11656 15:59:46 DEBUG [Sitecore Mvc]: Area resolution (RenderingLayoutAreaResolveStrategy) returned NULL

11656 15:59:46 DEBUG GetModelFromView 0 {FE5D7FDF-89C0-4D99-9AA3-B5FBD009C9F3}
  • Any console error or any error in logs? – Himanshu Agarwal Feb 19 at 5:29
  • Added debug info from logs in my edit. I'm not seeing any explicit errors. – john Feb 19 at 5:45
  • Hi John. Is there a difference in the layouts for the pages? According to the debug output, the non-working is resolving to “Empty” while the working is resolving to “Page.” – Craig Taylor Feb 19 at 10:41
  • I think I may have added the debug output for the "Empty" partial design (instead of the page), which is why the output is showing Empty as the name of the page. The debug output is the same on the actual page. – john Feb 21 at 8:37
  • If you switch to a different Theme (Basic2 or Wireframe) or switch to different Viewmode (Greyscale / Wireframe), do you see any difference? – Peter Procházka Feb 21 at 10:34
2

@john, look into your Site Groupings for SXA.

This sounds like a case where the web editing functionality isn't available for your page for your site grouping and it's falling to another site grouping or the website site. Ensure that you have Site Groupings that are appropriate for the page that specify the correct database and editing options that you're expecting.

Site Grouping Database

Site Grouping Flags

| improve this answer | |
0

This issue might be a problem with your custom layout and configuration of hiding placeholders.

Those special placeholders are coming from layout itself:

enter image description here

You need to create patch config file with this content:

<?xml version="1.0" encoding="utf-8" ?> 
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/"> 
    <sitecore> 
        <experienceAccelerator> 
            <mvc> 
                <!-- List of placeholders which should be hidden. --> 
                <hiddenPlaceholders> 
                    <layout id="$Insert_Your_Layout_ID_here$"> 
                        <placeholder name="head"/> 
                        <placeholder name="body-bottom"/> 
                        <placeholder name="body-top"/> 
                    </layout> 
                </hiddenPlaceholders> 
            </mvc> 
        </experienceAccelerator> 
    </sitecore> 
</configuration>

Where $Insert_Your_Layout_ID_here$ is ID of your custom layout. This will hide these placeholders the same way as it's hiding for OOTB SXA Layout.

More details in my blog post -> https://tothecore.sk/2019/05/13/hiding-body-top-and-other-placeholders-in-your-custom-mvc-layouts-with-sxa

| improve this answer | |
  • All pages are using the default SXA MVC layout (OOTB). Verified that the config is correct for hidden placeholders. The sites under the tenant that are experiencing this issue are using the same layout as the working sites (different tenant). – john Feb 21 at 8:35
  • Are you sure that the layout is not somewhere overridden in your tenant / site? Check also Page Designs. Hmm really strange issue – Peter Procházka Feb 21 at 9:52
  • The page design / layout is definitely being used on the pages as they are being rendered properly outside of the experience editor. I can also see the page design / partial designs selected for specific pages in the SXA experience editor ribbon. And I agree this is a very strange issue! – john Feb 21 at 15:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.