0

How to remove or hide category listing title using Custom Layout Update?

This is my code so for.

<reference name="product_list_toolbar" after="content">
  <action method="setData"><data>_current_grid_mode</data><mode>grid</mode></action>
</reference>

<reference name="product_list">
  <action method="setColumnCount"><count>5</count></action>
</reference>

enter image description here

7
  • on which position header or list postion,, can u give screen short
    – Amit Bera
    Sep 3, 2014 at 12:22
  • in a grid view category list Sep 3, 2014 at 12:25
  • give a screen short
    – Amit Bera
    Sep 3, 2014 at 12:27
  • check it. I need to remove the title Microsoft Office 365 Sep 3, 2014 at 12:32
  • are you want for a particular category?
    – Amit Bera
    Sep 3, 2014 at 12:37

2 Answers 2

2

Since it is not added individually by XML it cannot be removed via XML. As mentioned in Amit Bera's answer you change catalog/product.view.phtml or duplicate it if you need both options (with and without title).

However the easiest solution would be to hide this via CSS.

For all categories you could use:

.category-title { display: none; }

You said it was for a specific category page so you can further target it by going to the page and viewing the page source. Attached to the tag you can see the category's class name. In your example this class name is most likely 'category-microsoft-office-365'. Assuming that is correct you can use this CSS:

.category-microsoft-office-365 .category-title { display: none; }

This will hide the category title for only that specific category.

0

first of all it cannot remove using layout because this content is not coming from layout object...It is coming from category object

if  you need this remove then got catalog/category/view.phtml...

 put some logic to hidden this.

Just commit below code which is show title

<div class="page-title category-title">
    <?php if($this->IsRssCatalogEnable() && $this->IsTopCategory()): ?>
        <a href="<?php echo $this->getRssLink() ?>" class="link-rss"><?php echo $this->__('Subscribe to RSS Feed') ?></a>
    <?php endif; ?>
    <h1><?php echo $_helper->categoryAttribute($_category, $_category->getName(), 'name') ?></h1>
</div>

Or if you want for for a category then you can do this using below step:

1)create replicate of view.phtml as name customview.phtml and in customview.phtml commit title code.

2)add below on which set customview.phtml as it template

here 49 particular cat id

<CATEGORY_49>
    <reference name="category.products" >
         <action method="setTemplate"><templatecatalog/category/customview.phtml</template></action>
 </CATEGORY_49>

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.