XF 2.1 How to disable the stats for a specific 'category' node?

Kevin

Well-known member
I have a node that is a category node type and all of the child nodes of it are only link type nodes; there will never be any nodes in this category that contains threads, only link type nodes.

How can I disable the stats for this category node so that visitors don't see "0 / none" displayed when viewing the forum listing?

1570639486874.webp
 
I'm on my tablet so can't check the code but you can likely use the node ID coupled with the stats class and display none in extra.less.
 
Thanks, guys. (y)

For anybody else, my container node type is a category so in @batpool52!'s entry above change node--forum to node--category. I also added node-meta to the list of elements to be suppressed so that on smaller screens the display is also hidden. Swap "10" with the actual node ID that you're working with.

Less:
.node--id10.node--category
{
    .node-stats,
    .node-extra,
    .node-meta
    {
        display: none;
    }
}
 
Top Bottom