Add Home Link with functional active state to Menu Bar (Alternative Method)
This is an old revision of the document!
Add Home Link to Menu Bar |
For the Home link in the menu bar of the main template you can add some code to one of the template files.
Find the file called top.phtml in app/design/frontend/default/default/template/catalog/navigation/ and make the following change:
- <div class="header-nav-container">
- <div class="header-nav">
- <h4 class="no-display"><?php echo $this->__('Category Navigation:') ?></h4>
- <ul id="nav">
- <!-- HOME BUTTON HACK -->
- <li><a href="<?php echo $this->getUrl('')?>"><?php echo $this->__('Home') ?></a></li>
- <!-- HOME BUTTON HACK -->
- <?foreach ($this->getStoreCategories(10) as $_category):?>
- <?php echo $this->drawItem($_category) ?>
- <?php endforeach ?>
- </ul>
- </div>
- <?php echo $this->getChildHtml('topLeftLinks') ?>
- </div>

