I want to completely remove the div col-right sidebar from the default magento 1.9 theme.
I've tried creating a local.xml file containing:
<?xml version="1.0"?>
<layout version="0.1.0">
<default>
<remove name="catalog.compare.sidebar" />
</default>
</layout>
But this only removes the content of the div. I want to completely remove it from the html code so the page can contain more products on a single page.
Now:
enter image description here
Goal:
enter image description here
What should I try next?
2 Answers 2
You have to change the root template for <catalog_category_default> and <catalog_category_layered> inside your local.xml
i.e.
<catalog_category_default>
<reference name="root">
<action method="setTemplate"><template>page/2columns-left.phtml</template></action>
</reference>
</catalog_category_default>
Notice page/2columns-left.phtml. The template you are using is page/3columns.phtml
Take a look inside app/design/frontend/base/default/template/page/ for default layout templates that come with Magento.
-
It is better to edit the
catalog.xmlin this case, so you can set the correct template where it was intended to be defined - IMOJonathan– Jonathan2015年09月03日 12:14:33 +00:00Commented Sep 3, 2015 at 12:14
app\design\frontend\rwd\default\layout\page.xml
line 33-35 change to:
<default translate="label" module="page">
<label>All Pages</label>
<block type="page/html" name="root" output="toHtml" template="page/2columns-left.phtml">
products-grid products-grid--max-4-col first last oddtoproducts-grid products-grid--max-6-col first last odd= more products on a single page. I needcol-right sidebarto be gone.col-right sidebarso more products fit on a single page? That doesn't make any sense UX wise.