Can you use a conditional to see if a block has been added to an area?
Permalink
Hi There,
I have a 'Hero' area at the top of my templates that contains some mark up that I don't want output if the client hasn't added a block to the area.
Here's the area code:
And I don't won't the <div> output if the client hasn't added a block to this area -iIs this possible?
Any help would be much appreciated.
Cheers
Ben
I have a 'Hero' area at the top of my templates that contains some mark up that I don't want output if the client hasn't added a block to the area.
Here's the area code:
<div class="feature hero"> <?php $a = new Area('Hero'); $a->display($c); ?> </div>
And I don't won't the <div> output if the client hasn't added a block to this area -iIs this possible?
Any help would be much appreciated.
Cheers
Ben
Is this the best way of handling this?
Cheers
Ben