Expand my Community achievements bar.

July 31st AEM Gems Webinar: Elevate your AEM development to master the integration of private GitHub repositories within AEM Cloud Manager.

How to supress a page with Master Page with no data

Avatar

Level 1

Hi,

I have two master pages. The first page is an introduction page which has a separate Master data page. If more details are to be printed, my second page shows up. This comes with a different master page, as the pages following the first page will have a different master page. The second page may have the data or may not (Binding to a variable). When there is no data to be printed in the second page, in my case, the master page details are printed. So the second page comes with the header and footer alone. I do not want the second page to be printed at all when there is no data passed to it.

What do I do ?

Thanks for your help in advance.

Best Regards,

Moin

1 Reply

Avatar

Level 10

Hi,

You might need a flowed layout, where the first Master Page is restricted to one occurrence and that the data only flows onto the second page, if the data is present. This would mean that the second Master Page would only render if there is data present.

Do a search on the forum for Flowed Layouts.

Niall