Thread tagged as: Question

Making shared regions optional

Is there a way to make shared regions optional. My clients site has a 'winter alert' relating to access and they don't want to have to display this all year round. I've made it a shared region as it appears on a few pages of the website. Is there a way I can add a checkbox for them to switch it on or off - so it's always there in the backend and they just enable it when they need to?



Evie Milo

Evie Milo 0 points

  • 7 years ago

Something like this should do it?

We do this all the time on pages to let customers set up things (news mostly) in advance ...

<perch:if exists="publish">
- - - Your existing template code here - - -
<perch:content id="publish" type="checkbox" label="Publish?" order="1" value="yes" suppress="true" help="Tick the box to publish the alert" />

wow - that's superb - works perfectly. I love it. thanks for your help - very much appreciated!