0

I'm trying to move the top navigation to the left column of the page. Unfortunately I don't really know how I can manage this.

Since I have a lot of categories, I can't really use the Horizontal Navigation.

I have already tried changing the catalog.xml file, but it didn't seem to work. Cache is disabled, and its a clean install.

Thanks in advance!

I changed this:

<reference name="left_first">
    <block type="catalog/layer_view" name="catalog.leftnav" after="currency" template="catalog/layer/view.phtml">
        <block type="core/text_list" name="catalog.leftnav.state.renderers" as="state_renderers" />
    </block>
</reference>

to this

<reference name="left">
    <block type="catalog/layer_view" name="catalog.leftnav" after="currency" template="catalog/layer/view.phtml">
        <block type="core/text_list" name="catalog.leftnav.state.renderers" as="state_renderers" />
    </block>
</reference>

Unfortunately nothing changed. The path is: /magento/app/design/frontend/rwd/default/layout

2
  • can you show us the change you made in catalog.xml?
    – Alex Dinca
    Jul 3, 2014 at 9:43
  • Ok, I just edited my question. Jul 3, 2014 at 10:01

2 Answers 2

1

So firstly I am making a few assumptions.

  1. That you want to remove the normal navigation from the top and move it completely to the left hand-side,
  2. That you are going to style it yourself :)

Firstly want you want to do is create a local.xml in your theme so you can change the xml of pages easily.

Then you want to unset the current main navigation.

<reference name="top.menu">
    <action method="unsetChild">
        <name>catalog.topnav</name>
    </action>
</reference>

Now what you want to do is move this into the left column.

<reference name="left">
    <action method="insert">
        <block>catalog.topnav</block>
    </action>
</reference>

Now in the end your complete local.xml file will look as follows.

<?xml version="1.0"?>
<layout version="0.1.0">
    <default>
        <reference name="top.menu">
            <action method="unsetChild">
                <name>catalog.topnav</name>
            </action>
        </reference>
        <reference name="left">
            <action method="insert">
                <block>catalog.topnav</block>
            </action>
        </reference>
    </default>
</layout>

Now one very important thing to think about here is that not all pages have a left column. For instance in a default set-up the homepage and other cms pages do not have this as well as all product pages.

0

catalog/layer_view block is used to display the layered navigation filters (filter by attributes, price, or even category). What I understand you want to achieve is, display the full category structure inside the left column. In order to do it, you need to add a new block to the left column. A quick way would be to use the same block and template as in the header navigation.

Try this layout in catalog.xml:

<reference name="left">
    <block type="page/html_topmenu_renderer" name="left.catalog.nav.renderer" template="page/html/topmenu/renderer.phtml"/>
</reference>

*(haven't tested this yet)

1
  • Unfortunately this doesn't work. Nothing on the page changes. As I said, the Cache is DISABLED, so what could be the error..? Jul 3, 2014 at 13:42

Your Answer

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

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