cancel
Showing results for 
Search instead for 
Did you mean: 

How to remove left category from homepage?

How to remove left category from homepage?

 How to remove left category from home page using xml or other method? 

<?xml version="1.0" ?>
<layout version = "0.1.0">
    <default>
        <cms_index_index>
            <reference name="left">
               <block name="home-page-block">
                 <remove name="catalog.leftnav">
               </block>
              </reference>
           </cms_index_index>
    </default>
</layout>

I tried this code in local.xml but not working 

2 REPLIES 2

Re: How to remove left category from homepage?

1, your layout xml is wrong, cms_index_index shouldn't be in default, it should be under layout directly, and also you want to call remove action under refenrece directly

2, cms index is special, it doesn't call $this->loadLayout(); as many other controllers, instead, it loads only a few handlers (like 'default, 'cms_page'') itself, unless you want to remove left catagory from all cms, then you can use 'cms_page' handler, your best bet is to use custom layout in admin cms page manager,  simply write in custom layout

            <reference name="left">
                 <remove name="catalog.leftnav">
              </reference>

Re: How to remove left category from homepage?

Hi @Prashant_Tapase,

 

Here are 2 ways you can achieve it:

  1. Remove Left Bar using xml
  2. Change the Homepage Layout to 1 column
Was my answer helpful? You can accept it as a solution.
175+ Professional Extensions for M1 & M2
Need a developer?Just visit Contact Us Now