By pessato on
hi,
I was wanting to create a new region above the header in the zen theme. I want to be able to put blocks in this region.
What would be the best way to do this?
thanks in advance,
pessato
hi,
I was wanting to create a new region above the header in the zen theme. I want to be able to put blocks in this region.
What would be the best way to do this?
thanks in advance,
pessato
Comments
Add a region to your
Add a region to your theme.info file.
regions[headerTop] = Header TopIn your page.tpl.php, add the code -
<?php print $headerTop; ?>Clear cahe and configure your block.
thanks!
perfect, thanks mate!!
Just remember that the region
Just remember that the region's machine name has to work as a PHP variable name, so you can't use hypens (-) in the name. Underscores work fine :)
http://www.fonant.com - Fonant Ltd - Quality websites
Different
It's probably changed since this topic was posted, but the way you print Zen regions now is using the following format:
<?php print render($page['MACHINENAME']); ?>Clear caches and your region should now be available on the blocks page. Maybe this will help someone.