Add class to kirbytext elements

Good morning,

I am trying to add classes to element inside the kirbytext output.
For example: I want to add some classes to a blockquote element.

<blockquote class="bg-soft-primary border-0 rounded-lg text-center text-dark font-size-2 font-weight-bold text-lh-lg p-5 my-5">
  "This is great, thanks!"
  <span class="d-block text-muted font-size-1 mt-2">- John Example</span>
</blockquote>

I tried to follow this reusing KirbyTags example. I made this plugin. Do I have to register it in the config? Or how does this work? I do not really understand the docs. :confused:

Thanks!

1 Like

The files where you should put everything are always named in the recipe above the code:

A plugin always consists of a folder in site/plugins and an index.php to register the plugin.

Is that all you have to do? No reference anywhere else?

Thanks!

Exactly, every folder in the plugin folder that has an index.php is automatically loaded.

1 Like

That’s great. Thank you so much for your response.