Is there any way to have a conditional (if) statement that checks for the existence of data within a repeatable region?
i.e. I want to be able to have something like this:
Where the entire auction section is hidden if I've not populated the backend with lot information.
Thank you.
i.e. I want to be able to have something like this:
- Code: Select all
<cms:repeatable name="auction_lots" label="Auction Lots" >
<cms:editable name="lot_title" type="text" label="Lot Title" />
<cms:editable name="lot_description" type="nicedit" label="Lot Description" />
</cms:repeatable>
...
<cms:if 'auction_lots' >
<section id="auction" class="auction">
<h1>Auction</h1>
<article>
<cms:show_repeatable 'auction_lots' >
<h2 class="lot-title"><cms:show lot_title /></h2>
<div class="lot-description">
<cms:show lot_description />
</div>
</cms:show_repeatable>
</article>
</section><!-- #auction -->
</cms:if>
Where the entire auction section is hidden if I've not populated the backend with lot information.
Thank you.