1

I just upgrade from Mag CE 1.5 to 1.7.0.2 and heck, fall in to troubles in a row..fixed a few but stuck at top menu..

app/design/frontend/default/tenniskarma/template/page/html/topmenu.phtml contains

* @see Mage_Page_Block_Html_Topmenu
 */
?>
<?php $_menu = $this->getHtml('level-top') ?>

<?php echo var_dump($_menu) ?>
<?php if($_menu ==  ""): ?>

<div class="nav-container">
    <ul id="nav">
    <?php echo 'test test test' ?>
        <?php echo $_menu ?>
    </ul>
</div>
<?php endif ?>

and istead of menu, it prints out string "" and test test test, meaning that I am not getting $menu back...

see this

MY menu does show at all, can somebody tell me whats happening with me?

my page.xml holds

 <block type="page/html_header" name="header" as="header">
                <block type="page/template_links" name="top.links" as="accountLinks"/>
                <block type="page/switch" name="store_language" as="store_language" template="page/switch/languages.phtml"/>
                <block type="core/text_list" name="top.menu" as="topMenu" translate="label">
                    <label>Navigation Bar</label>
                    <block type="page/html_topmenu" name="catalog.topnav" template="page/html/topmenu.phtml"/>
                </block>
                <block type="page/html_wrapper" name="top.container" as="topContainer" translate="label">
                    <label>Page Header</label>
                    <action method="setElementClass"><value>top-container</value></action>
                </block>
</block> 

for menu inclusion..

please help me..I am near to striking my head with wall

3
  • What is with the first if statement... should be if($_menu)
    – pspahn
    Commented Mar 24, 2013 at 5:59
  • Did you try to copy the default template? if this works, then change it until you have your old styling - or an error occured, then you know what to fix Commented Mar 24, 2013 at 15:52
  • This looks like it's fixed now. Please add an answer explaining what you did to fix it.
    – Marius
    Commented Jul 9, 2014 at 7:32

2 Answers 2

2

Have you tried reindexing your site? Todo so goto Magento's Admin > System > Index Management, select any Indexes that may need their Data Reindexed, and click Submit.

0
1

Try changing

<?php $_menu = $this->getHtml('level-top') ?>

to

<?php $_menu = $this->getHtml('topMenu') ?>

level-top is not declared.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.