Skip to main content
Closed for Voting

category class

Related products:Freshdesk
  • August 30, 2016
  • 6 replies
  • 24 views

 Hi, it would be great if each category had a body class, so one could more easily customize some details of each layout.

6 replies

sajesh.krishnadas
Contributor
Forum|alt.badge.img+6

Hi Alice, it would be great if you can elaborate more about your requirement. 


Are you referring to the knowledge base categories? If yes, do you want to customize a specific category in your portal to have a different layout? 


In the above cases, you can go to Admin -> Portals -> Customize portal (on the required portal) -> Layout & pages -> Portal pages -> Select 'Solutions category home'. In this page, you need to make the necessary customization to the page with the condition to change the layout for a particular category by specifying the category ID. 


In case you want to customize a particular folder, you need to select 'Article list' from the Portal pages and make the required customization by specifying the folder ID. 


  • Author
  • Contributor
  • August 30, 2016
Hi Sajesh,

thanks a lot for your answer. I see what you mean, but I have some questions, I try to explain better:

- I would like a custom visualization for a specific Solutions Category Home & its Article Lists (namely the video tutorial) + another visualization for all other categories and lists. So, basically I need two custom layouts.

What is not clear to me in regards of what you suggested is: if I specify one ID what happens to the layout of the others?

Thanks!

 


sajesh.krishnadas
Contributor
Forum|alt.badge.img+6

Basically, all the pages will be in their default format and layout. When you specify a particular ID and customize the layout, it creates an exception and the changes are considered for the specific ID only. However, you can preview the changes before publishing it. 


  • Author
  • Contributor
  • August 30, 2016
this means that one cannot have two custom layouts, is that right?

 


  • Author
  • Contributor
  • August 30, 2016
adding the id at the beginning such as here <section class="main content" id="solutions-category-17000033579"> doesn't seem to work for me, the custom layout works for all categories anyway.

is is possible to make a conditional statement such as {% if article.category: 17000033579 %} ?

thanks!

 


sajesh.krishnadas
Contributor
Forum|alt.badge.img+6

You mean two custom layouts for two different categories right? That's possible. You can specify the required IDs and customize the layout for each of your categories.