cloneamental

Permalink
Hi
I am new to c5 and trying to set up a new site. I am using the colneamental theme.

I would like to move the sitewide header navigation block below the sitewide header title and sitewide header search, so that the sitewide header navigation block can use the full width of the webpage.

I have edited the packages/cloneamental/themes/cloneamental/elements/header.php to make a new row below and insert the sitewide header navigation block. This works, however the original sitewide header navigation block in the middle column is still in place and when I insert the auto-nav block I get 2 menus in the header.

How is it possible to remove the sitewide header navigation block in the middle column ? I assume there is another file that overrides the cloneamental header.php file.

Can anyone help me ?

 
hutman replied on at Permalink Reply
hutman
Can you provide the code of your header.php? It sounds like you duplicated the Global Area instead of moving it.
alanek replied on at Permalink Reply
Hi
Thanks for your reply, I double checked everything and now I no longer have 2 “sitewide navigation blocks” (maybe I did not refresh my browser when I did the original changes.)

Now that I have my sitewide navigation block as I want it I am not sure how to handle the middle column, sorry about this I am not a programmer.

My code is attached
<?php  defined('C5_EXECUTE') or die("Access Denied.");
$this->inc('elements/header_top.php');
$as = new GlobalArea('Header Search');
$blocks = $as->getTotalBlocksInArea();
$displayThirdColumn = $blocks > 0 || $c->isEditMode();
?>
<header>
    <div class="container">
        <div class="row">
            <div class="col-sm-4 col-xs-6">
                <?php 
                $a = new GlobalArea('Header Site Title');
                $a->display();
                ?>
            </div>
.

Is it ok to leave this middle column blank as above? or could I put the nav language switch in this space ? (in the same row as the site title and search).

At the moment when in edit mode and I try to put the nav language switch in the middle column the "nav switch" block makes a new row below the the site title and above my new sitewide navigation block. So I guess I need some code in the middle column
hutman replied on at Permalink Best Answer Reply
hutman
So what you have done here is you have removed all of the areas from the middle column. So you can either remove the middle column all together, or you can add a new area inside of it and utilize it. If you want to add a new area into it and utilize it you will want to add code like this into that div

$a = new GlobalArea('Header Middle Column');
$a->display();

That code creates a new "area" which is where you can place blocks. If there is no area you can't place a block there. Each area has to have a unique name (value in the quotes).
alanek replied on at Permalink Reply
Thank you very much, everything is now working as I want. Your help was most appreciated