Separate landing page / change nav code in header?

Permalink Browser Info Environment
First off - great theme! I bought it a while back, decided not to use it, but then the project got more complex and here I am!

My client wants a "landing page". Sadly. the best way I can figure how to do this is to have to add the nav to each page from stacks, rather than having it dynamically created. In this manner I can "not add" it to the home page, thus creating a landing page without navigation.

See this example:

http://www.stagingseydoux2.ch/

My question is, how should I code the nav in header.php? Can it include all the template goodness, or will I have to add that to the block in stacks?
Would this be correct:
<nav>
       <?php  
         $a = new Area('Navigation');
         $a->display($c);
         ?>
    <div class="clearboth"> </div>
    </nav><!-- nav ends -->


I considered moving the nav to the beginning of pagemeta.php, but I wasn't sure what that would do to "feature" (What's that for?- not sure I need it)
I have already changed quite a bit ("forked" the theme) And although there's a bit of running around between stylesheets - it's all very clear.
Thanks for any suggestions!

Type: Discussion
Status: New
arlenesey
View Replies:
arlenesey replied on at Permalink Reply
arlenesey
OOPs - Now noticed that pagemeta.php is used for blogs - sorry that suggestion won't work...
c5mix replied on at Permalink Reply
c5mix
So basically you just want the Home page type to not have a navigation at all? Probably the best way to do that would be in the header.php file replace this code:
<nav>
       <?php
      $bt = BlockType::getByHandle('autonav');
      $bt->controller->displayPages = 'top';
      $bt->controller->orderBy = 'display_asc';                    
      $bt->controller->displaySubPages = 'all'; 
      $bt->controller->displaySubPageLevels = 'all';
      $bt->render('templates/slate_main_nav');
      ?>
        <div class="clearboth"> </div>
    </nav><!-- nav ends -->

With this:
<?php if (!$c->getCollectionTypeHandle() == 'home') { ?>
<nav>
       <?php
      $bt = BlockType::getByHandle('autonav');
      $bt->controller->displayPages = 'top';
      $bt->controller->orderBy = 'display_asc';                    
      $bt->controller->displaySubPages = 'all'; 
      $bt->controller->displaySubPageLevels = 'all';
      $bt->render('templates/slate_main_nav');
      ?>
        <div class="clearboth"> </div>
    </nav><!-- nav ends -->
<?php } ?>


Basically what that does is have it output the navigation on any page type that isn't the home page type.
arlenesey replied on at Permalink Reply 1 Attachment
arlenesey
Thanks C5mix

I tried your suggestion once, but it didn't seem to work, but it could be I did something wrong. I will start over and try it again today.
What I also realized is that the excluding first page from nav brings what the Germans call a "rat's tail" of problems - for instance, the breadcrumbs don't present properly.

Because the breadcrumbs template always wants to start at "Site" or "Home" (but ist's not included in nav), the delimiter appears at the beginning of the line. (see screenshot)
I need the breadcrumbs to show only starting from the child pages, without delimiter at the beginning.

Even if I use a separate theme for the home page, the breadcrumbs template will always want to show the site name. HMMMMM. (Wheels turning)
I tried tearing it all out and just using the breadcrumbs block, but it seems counter-productive.

Anyway I am learning a lot so that's a good thing.

If you have any ideas I appreciate the help. I will try your fix again today...

Thanks!
c5mix replied on at Permalink Reply
c5mix
You're welcome!
Hmmm, that might be a bug with concrete5's breadcrumb template. Might want to check the main forums / bug area to see if anyone else has a solution/fix.
arlenesey replied on at Permalink Reply
arlenesey
Okay, I had a chance to go in and try this fix again, and there are two problems:
1. The nav is gone from all pages, not just home.

2. I need to remove Site Name and Feature also. When I tried to use your clever code including these areas, OOOPPPSS, I got a big error message.

Take a look at
http://www.stagingseydoux2.ch/

and you'll see what I mean.
Home should just have the slideshow and "enter" (and footer)

following pages should include site name, feature and nav area.
I got rid of the page meta and am using a sidebar nav, so that problem is solved...
Thanks for any suggestions...
arlenesey replied on at Permalink Reply
arlenesey
Okay-my next step is convert the hard-codeded areas site name, featured and nav - to editable areas - then I can include or exclude as I wish. Not sure if I have the skill. I'll keep the forum posted.
arlenesey replied on at Permalink Reply
arlenesey
So here's what I've ended up doing:

I copied the theme, renamed it and made a new description.txt and thumbnail.png. Eliminated all extraneous page types except default.php and home.php.
Cut the "logo" and "header" areas, and "nav " (important - leave "container"!) out of header.php.

Loaded it up, changed the home page theme to the new alternative and "bingo".

If anyone knows why this is a bad solution, please let me know.
c5mix replied on at Permalink Reply
c5mix
That sounds good. Glad you got it sorted out. Let me know if you need anything else.

concrete5 Environment Information

Browser User-Agent String

Hide Post Content

This will replace the post content with the message: "Content has been removed by an Administrator"

Hide Content

Request Refund

You have not specified a license for this support ticket. You must have a valid license assigned to a support ticket to request a refund.