Hello all,

I'll be damned if I can find where the navigation positioning is set in Zen? I've made my own sub-theme, and I'm having troubles with the navigation bar, as it sometimes just moves to another place...

I'm thinking of trying to move the navigation stuff to be output before the content instead as that would probably ease things up a bit. But I first have to know where it's positioned in the css?

Thanks

Comments

SweeneyTodd’s picture

I assume you are using a sub-theme not changing Zen.

Have you fixed the IE issues?

http://drupal.org/node/910902
http://drupal.org/node/651146

If you want to modify the subtheme you will have to copy the .tpl.php files from the main Zen theme into your subtheme and clear the theme cache.

The position of the navigation is set in page.tpl.php from line 197 to 214. See code below:

      <?php if ($primary_links || $navigation): ?>
        <div id="navigation"><div class="section clearfix">

          <?php print theme(array('links__system_main_menu', 'links'), $primary_links,
            array(
              'id' => 'main-menu',
              'class' => 'links clearfix',
            ),
            array(
              'text' => t('Main menu'),
              'level' => 'h2',
              'class' => 'element-invisible',
            ));
          ?>

          <?php print $navigation; ?>

        </div></div> <!-- /.section, /#navigation -->

Moving the position of the navigation is a bit of a pain in Zen because of the way the css works and the positioning of the rest of the content below it.

The css for the navigation is in layout-fixed.css or layout-liquid.css. Just do a search on #navigation in those files.

ruccola’s picture

Thanks, haven't looked at the IE issues yet.

Ok, I need to really figure out layout-fixed.css then, because I don't get how the navbar is positioned vertically in there.

Long story now, hang on:
I have a "highlights block" on my front page, with an image of 600x400, a title and a link. This content changes if I create a new piece of content and set "promote to front page". For some reason the entire front page became weird when I created a new "article" with CKEditor and promoted it to the highlights block. It also screwed up my "article index" page where I list all the articles, where the navbar for some reason appeared beneath ALL content.

Now, this is where it becomes interesting. I then created a piece of "news" with the same size image, title and so on. And nothing screwed up! I then created a new "article" and again everything worked. The only thing different between these and the first one is that the first one had images added in the body text (via CKEditor). I really can't see how this can change the CSS on the front page, but hey, what do I know :)