Download
We're evolving to serve you better! This current forum has transitioned to read-only mode. For new discussions, support, and engagement, we've moved to GitHub Discussions.

Table of Contents Header in Tiny Editor

  • #8918
    Avatar photo[anonymous]

    Hi,

    Could anyone point me in the right direction for changing the “Table of Contents” h3 header in the Tiny editor?

    It auto sets the header as a h3 tag which then lowers my website accessibility score because other post sub headers are h2 tags.

    Although I can highlight the “Table of Contents” text the editor will not let me change it from h3 to h2. I can change it in the html but as soon as I refresh the table of contents it goes back to a h3 header.

    Any ideas?

    #8943
    Avatar photo[anonymous]

    Hi,

    You must override TinyMCE settings and change option: toc_header from “h3” to “h2”

    You can do it by override: https://getpublii.com/dev/how-to-add-custom-config-or-js-for-post-editor/

    #8950
    Avatar photo[anonymous]
    Tomasz Dziuda wrote:

    Hi,

    You must override TinyMCE settings and change option: toc_header from “h3” to “h2”

    You can do it by override: https://getpublii.com/dev/how-to-add-custom-config-or-js-for-post-editor/

    Many thanks Tomasz