Can we restrict a Sitecore item to have only one header and footer renderings?

182 Views Asked by At

I am using Sitecore 8.2 and I have many items, created from the same template. Though I have set the renderings in the standard value of the template for common components like header and footer, but want to make sure that these renderings can't be added twice.

Can we achieve this? If yes, what the ways?

2

There are 2 best solutions below

0
Jay S On

If you do not make the rendering available to be added to a placeholder, then no author will be able to select it from the Component selection dialog in Experience Editor.

The "Allowed Controls" list is how you will specify which controls are allowed to be added to a given placeholder.

0
Akshansh Dwivedi On

If you mean you want authors to not add the rendering twice, then probably you can add a processor into < insertRenderings > pipeline. Check if that helps.