We offer professional Design/Code Customisation and Website Optimisation Service Request Customisation
  • Status: Closed
  • Closed by: Marek (marek)
  • Closed on: 10.02.18, 21:57
  • Reason: Closed
  • Comment: Glad to help!

Ticket #11451 - Can't find where the category page model can be amended

Hello Marek

I’m now looking for the generic category page model
So far if I look at it
it shows 1/ a subcategories list

           2/ a pic 
          3/ a video
          4/ a content 

I get where the pic and subcategories list come from

I’m trying to understand where in which model file / UI

      A/ I could see/modify a condition to not display the subcategories list if there is none below
      B/ rid or not of the video
      C/ get anything else (full or empty HTML content) in place of the awful 404

in short that is control that category page model

see attachment


categories model.png (1.12 MiB)

This ticket does not depend on any other tickets.

mahieux (lepetitcoton) 18 Jan 2018, 11:06


OK I think I read from the code that content is generated by a DB query to populate matching products, since i have none for no surprise

Marek (marek) 18 Jan 2018, 22:59

Why you need edit theme files? you can configure the page through back office

mahieux (lepetitcoton) 19 Jan 2018, 00:52

mmm and where ?
As if I asked I did not find what I was looking for

so I'm still puzzled for A/ & B/

Marek (marek) 19 Jan 2018, 11:50

a. the file is themes/alysum/templates/catalog/listing/category.tpl
b. just disable the module pk_video

mahieux (lepetitcoton) 19 Jan 2018, 14:27

got B/ done easily
Now is that standard in PS that a product which comes with no Child category displays a sub cat header , or is it a PK flaw ?
any elegant way to evaluate an empty div afterward and a hidden css then ?

Marek (marek) 19 Jan 2018, 14:29

try following CSS:

.CLASS:empty {display:none}
mahieux (lepetitcoton) 19 Jan 2018, 16:28

brilliant idea , execpt taht I will have to go thru a JS because a child div is empty and I need the parent to hide
but anyway that led me to sthg

Marek (marek) 20 Jan 2018, 14:22

is the ticket solved now?

mahieux (lepetitcoton) 24 Jan 2018, 11:01

Not really as this would apply foRr 1 DIV , here the pb is parent child related

pb is that is a div as no content then the PARENT should not be displayed and it may not be the direct parent
should be something like

if category_tree is empty then section ps_categorytree should not be displayed

Sans titre.jpg (81.1 KiB)
Marek (marek) 24 Jan 2018, 11:06

give me a link to page where I could see the issue

mahieux (lepetitcoton) 24 Jan 2018, 14:13

e.g https://lepetitcoton.com/fr/21-bodies its an end of teh categories subcategory tree , in short a 'product'
and it therefore should not show any subcategory header

                                        Categories    SVG-Icon

since there are none

Marek (marek) 24 Jan 2018, 15:01

That is native prestashop module, and you can ask prestashop developers to fix that issue