How to include header on all pages?
Permalink
Hi :-)
I'm wondering how I can include one file, or have an editable area that is the same for all pages?
I kind of made it happen, but then I couldn't add logo(unless I hardcoded it, like in the codeblock below.
I want an area which comes with all pages with option to add content. But if there already have, lets say, added a auto-nav block, it comes along automatically.
Any ideas? Thanks in advance :-D
I'm wondering how I can include one file, or have an editable area that is the same for all pages?
I kind of made it happen, but then I couldn't add logo(unless I hardcoded it, like in the codeblock below.
<div class="nav-wrap"> <nav> <div id="logo">My Logo</div><br> <img id="burger-ikon" src="<?=$view->getThemePath()?>/images/burger-ikon.png"> <br> <div id="line"></div> <?php $nav = BlockType::getByHandle('content'); $nav = BlockType::getByHandle('autonav'); $nav->controller->orderBy = 'display_asc'; $nav->controller->displayPages = 'top'; $nav->controller->displaySubPages = 'all'; $nav->controller->displaySubPageLevels = 'custom'; $nav->controller->displaySubPageLevelsNum = 2; $nav->render('templates/themetest');
Viewing 15 lines of 18 lines. View entire code block.
I want an area which comes with all pages with option to add content. But if there already have, lets say, added a auto-nav block, it comes along automatically.
Any ideas? Thanks in advance :-D
Look here for explanation..
http://www.concrete5.org/documentation/recorded-trainings/theme-dev...