WordPress Table of Contents Plugin (CMTOC) - TOC - Exclude by Class


General Settings

Navigate to the Table of Contents tab of the WordPress Table of Contents plugin settings.

Table of contents settings tab - WordPress Table of Contents Block
Table of contents settings tab

Under General Settings, you can type the HTML class name of the element. Then headings inside the container having this class among its classes will be excluded.

Excluding headings with specific class from TOC - Add Table of Contents WordPress
Excluding headings with specific class from TOC

This is how the example Table of Contents looks.

TOC example - Floating Table of Contents WordPress
TOC example

The first part of the page including the <h3> tag is now wrapped with the div with the class "testing" as we don't want it to appear in Table of Contents.

Adding specific class to the part of the content - WordPress TOC Plugin
Adding specific class to the part of the content

After the save, we can see that the first heading no longer appear in the Table of Contents:

Example of TOC with excluded item - TOC Table of Contents WordPress Plugin
Example of TOC with excluded item

More information about the WordPress Table of Contents Plugin

Other WordPress products can be found at CreativeMinds WordPress Store

Let us know how we can Improve this Product Documentation Page

To open a Support Ticket visit our support center
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.