J
J
JefAir2020-12-13 16:34:05
OctoberCMS
JefAir, 2020-12-13 16:34:05

How to display additional content on the category page?

Rainlab's blog is installed in October cms. The blog works normally. It has several categories. If you go to the category 1 page, then it will display posts related to this category 1.
In the admin panel for a category, you can fill in only 2 fields (name and description).
The title I use for title (meta)
The description I use for description (meta)
It works like this:

<?php
function onEnd()
    {
        if ($this->category)
            $this->page->title = $this->category-> name;
            $this->page->description = $this->category-> description;
    }
?>

I want to be able to display some custom text in addition to the title and description. Roughly speaking, I am missing one field in the category admin, which I could fill in and display in the place I need on the category page.
To put it more simply, I need to add a description for each category, but I only have one template page for displaying categories, which displays posts through :slug.
Can you please tell me how this can be implemented?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry, 2021-02-15
@i__dmitry

You need to use the plugin extension: https://octobercms.com/docs/plugin/extending

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question