Forum Discussion

msavage's avatar
msavage
Expert
12 years ago

restrictions on nestable pages?

I've been working on some new pages and I was attempting to create a consistent header across all of them.  However, I noticed a few things:

 

1) the default Header page has an override that prevents it from being nestable (it will revert false -> true changes in XML view on save, toggle is hidden in Canvas view), which makes it impossible to make a single Header and nest it in each page.  The result is constantly having to add all of the header modules to each new page you create, which is highly inefficient.

 

header_page

 

 

 

2) As a workaround, I created a new Page (e.g. Header2) and a new Layout (Header2), assuming that I could make an exact copy of the current header objects with custom content, which would hopefully not be subject to the constraints of #1 above.  I can see the 'nestable' toggle now, but the same thing is happening on save- it reverts to 'false'. 

 

It's a bit tedious and likely to cause errors if this replication must occur manually on every page we maintain.  I've also noticed that the footer page can be nested, which thoroughly perplexes me, as it's common for a site to have consistently fixed header/footer working in tandem.  Is there something I'm missing?  I've seen new system pages without the frontend header content, but the page layout has the header sections (without the actual custom modules in the layout, though), so maybe they're added by default somehow?

 

blank header items in nav layout

  • I did some research on this and I believe I've discovered the bug, I'm filing a ticket to have this fixed. The bug is this:

     

    Certain core pages (such as Footer and Header), are set as "nestable=true" by default, so that they can be embedded in other pages. However, modifying any of these pages in the Page Editor, then saving them, auto-sets "nestable=false", thereby rendering them un-embeddable in other pages.

     

    This is what happened in your case, since Header was edited and saved. For now, if you would like me to fix this for you (directly in the Header asset), send me a PM. Hope this helps!

     

    Sincerely,

    Venk

  • A follow up to point #2 - not sure if this is a bug, but it seems odd to me.  The new Lithium-created page did add the header by default in the xml, but didn't load any of the components that belong in the header quilt.  I assume this happened because that component isn't nestable?

     

      <add to="common-header">
        <component id="quilt:Header"/>
      </add>

    • VenkS's avatar
      VenkS
      Lithium Alumni (Retired)

      Hi, I have some information on this functionality, if you could answer some questions for me I can look into it further and hopefully have an answer for you very soon! If you prefer, you can answer these questions in a private message:

       

      1) What site are you working on? I would like to check the configuration for your site (as there are multiple version of the Header).

      2) When you created Header2, did you set it to be "nestable" when you created it (there is an option in the popup window where you enter the information about your new page), or are you trying to set it to be "nestable" after you created it (the checkbox in the Page Editor).

      3) For Header2, can you verify in the XML tab that "nestable" is set to "false"? There is currently a bug in Studio where if you click on the "nestable" checkbox and click Save, you need to refresh the page to see that the "nestable" checkbox is now checked.

       

      To explain a little more about the "nestable" feature, the idea is to provide a way to nest pages within other pages, however we don't want to confuse developers by having this functionality on by default, because most pages cannot be nested within other pages. So we use this property to limit the use of such nestable pages. The fact that the Header is showing up as not "nestable" I think is a bug, I'm looking into that right now.

      • VenkS's avatar
        VenkS
        Lithium Alumni (Retired)

        I did some research on this and I believe I've discovered the bug, I'm filing a ticket to have this fixed. The bug is this:

         

        Certain core pages (such as Footer and Header), are set as "nestable=true" by default, so that they can be embedded in other pages. However, modifying any of these pages in the Page Editor, then saving them, auto-sets "nestable=false", thereby rendering them un-embeddable in other pages.

         

        This is what happened in your case, since Header was edited and saved. For now, if you would like me to fix this for you (directly in the Header asset), send me a PM. Hope this helps!

         

        Sincerely,

        Venk