The TOC plugin for Bludit CMS enhances the appearance of your articles by automatically generating a Table of Contents (TOC) based on the headings found within your content. This plugin is simple to use and easy to install.
- Automatically detects and generates a Table of Contents (TOC) based on the h2 to h6 headings in your article.
- Customize the plugin to display only h2 and h3 headings if desired.
- The TOC will only be displayed if headings are found in your article. If no headings are present, the TOC will not be shown.
- Download or clone the repository.
- Place the plugin in the
/bl-pluginsdirectory of your Bludit installation. - Activate the plugin from the Bludit Dashboard.
Once activated, the plugin will automatically:
- Scan your article for h2-h6 headings.
- Generate a Table of Contents at the beginning of your content.
- Allow you to customize which heading levels (h2, h3, etc.) are displayed in the TOC.
- Don't forget to add
<?php Theme::plugins('siteBodyBegin'); ?>right above<?php echo $page->content(); ?>in your "page.php" theme.
If no headings are found in your article, the TOC will not be displayed.
You can customize the plugin to show only specific heading levels (e.g., h2 and h3) by modifying the plugin's configuration.
This plugin is licensed under the MIT License.