I modified my template to display the primary links in the header section. It works great on my development system but after I upload the entire template with css templates to my site, they do not show up. I verified that all template files uploaded correctly. When viewing the rendered pages source, the primary links section is missing.

Can anyone help?

My code:

  <div id="wrap">
    <div id="header">
<?php if ($site_slogan) { ?><p id="subtext"><?php print $site_slogan ?></p><?php } ?>
<img id="frontphoto" src="<?php if ($logo) { ?><?php print $logo ?><?php } else { ?><?php print base_path(). path_to_theme(); ?>/logo.gif<?php } ?>" width="336" height="70" alt="" />
      <?php if ($site_name) { ?><h1 class="site_name"><a href="<?php print base_path() ?>" title="<?php print t('Home') ?>"><?php print $site_name ?><?php } ?></a></h1>
	  
<?php if ($primary_links) { ?>
        <h2 class="hide"><?php print t("Primary Links:")?></h2>
          <ul id="primary-links">
            <?php foreach ($primary_links as $link) { ?>
              <li><?php print $link?></li>
            <?php }; ?>
          </ul>
      <?php }; ?>
   </div>

......

Thanks

Comments

kuahyeow’s picture

Yuck, what is that mess? From what code I can see seems to be ok...

Lets eliminate some possibilities:
1) Is the primary links checkbox ticked under themes->configure?
2) Do you have any primary links on your new site?

--
Cheers,
Thong

Tip: http://drupal.org/forum-posting
Website: http://www.edoodle.co.nz

theichurch’s picture

If it worked before and doesn't now go into the themes config and make sure primary links are enabled.

If you are on 4.7 then also check admin -> settings -> menu and see if the primary menu is set to your primary menu.

If not then please post back.

rvlong’s picture

Thanks for the help. Found where to enable primary links and was able to resolve the problem.

Thanks everyone for your response :) I'm still new to Drupal and getting used to the interface. Great product, just a learning curve at this point ;)

Thanks again!