Jump to content

Hide subcategories in Category page at Prestashop 8.1.1 (Solved)


beluafi.ilustracion

Recommended Posts

I would like to hide the subcategories that appear on the category pages. Not the tree that appears on the left margin but the other list that comes out in the central body. In fact, I would like to hide everything that appears between the header and the products.

I have been looking for several hours and all the solutions that appear to me are for old versions of Prestashop and it is possible that none of the solutions that I have found work for me. I am using 8.1.1.

Thank you!

Edited by beluafi.ilustracion (see edit history)
Link to comment
Share on other sites

Hi,

You need to search for code in the categories tpl file which shows the results of sub-categories in the listing page, then need to comment code in the tpl file of categories products listing.

I found below forum post useful. The post has a solution for 1.7, I think it will work for version 8 as well as the new version has old version code and some enhancements.

 

 

Link to comment
Share on other sites

17 hours ago, beluafi.ilustracion said:

I would like to hide the subcategories that appear on the category pages. Not the tree that appears on the left margin but the other list that comes out in the central body. In fact, I would like to hide everything that appears between the header and the products.

I have been looking for several hours and all the solutions that appear to me are for old versions of Prestashop and it is possible that none of the solutions that I have found work for me. I am using 8.1.1.

Thank you!

Hi.

Did you mean to hide the subcategories as crossed out?

./themes/your_theme/templates/catalog/listing/product-list.tpl

(The placement of the subcategory block may be different, depending on your template)

Find and comment:

An asterisk is added after the first character { and before the last character }

{*block name='subcategory_list'}
      {if isset($subcategories) && $subcategories|@count > 0}
        {include file='catalog/_partials/subcategories.tpl' subcategories=$subcategories}
      {/if}
    {/block*}

obrazek.thumb.png.a90c2d367a0753904dbf4d0cc3726dcd.png

Edited by ps8moduly.cz (see edit history)
Link to comment
Share on other sites

I have already comentented the tpl and it still appears.😖

 

 

 

On 10/25/2023 at 7:46 AM, ps8moduly.cz said:

Hi.

Did you mean to hide the subcategories as crossed out?

./themes/your_theme/templates/catalog/listing/product-list.tpl

(The placement of the subcategory block may be different, depending on your template)

Find and comment:

An asterisk is added after the first character { and before the last character }

{*block name='subcategory_list'}
      {if isset($subcategories) && $subcategories|@count > 0}
        {include file='catalog/_partials/subcategories.tpl' subcategories=$subcategories}
      {/if}
    {/block*}

obrazek.thumb.png.a90c2d367a0753904dbf4d0cc3726dcd.png

 

Link to comment
Share on other sites

  • beluafi.ilustracion changed the title to Hide subcategories in Category page at Prestashop 8.1.1 (Solved)

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...