Table Of Content Plugin

#20253
  • Resolved Michael Davis
    Rank Math free

    So, looking around I get bits and pieces of the info I am looking for. This plugin has been awesome so far, but I am noticing a common issue that should be address to help with custom sites that do not use your recommended plugins. Mainly because those particular plugins other cost a lot or they don’t keep up with updating them..

    So here we are with a plugin not on your list. I found one ticket that puts out info about using:
    /**
    * Filter to add plugins to the TOC list.
    *
    * @param array TOC plugins.
    */
    add_filter( ‘rank_math/researches/toc_plugins’, function( $toc_plugins ) {
    $toc_plugins[‘plugin-directory/plugin-filename.php’] = ‘Plugin Name’;
    return $toc_plugins;
    });

    In the theme’s function.php file, which is great, but doesn’t help users, like me, that are new to wordpress and are not fully knowledgeable about where to find these or even how to find the exact file needed to put over the “plugin-filename”.

    My question is that above. How do I find the exact file needed to put in the code above, and to make sure to get the correct filename of the addon. Mine is tocpack-premium, I put all that in, but it is not working, so clearly I am not doing this correctly.

    –side note–
    Maybe adding an option to dump a plugin name in the backend or possibly expanding your list. It would help us tremendously.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Tom Robak
    Rank Math business

    up. I am using TOC from Ultimate Addons (gutenberg)

    Hello,

    Thank you for contacting Rank Math and sorry for any inconvenience that might have been caused due to that.

    I will submit this suggestion to our dev team. To be able to make this work, you need to login to your site via FTP and navigate to the /wp-content/plugins/ folder to be able to identify the {plugin-directory} of your TOC plugin. You will use this folder name on {plugin-directory}.
    Next, open this plugin folder and copy the main plugin file name which should be something like tocpack.php and paste this name under {plugin-filename.php}.
    Here is an example of how the code will then look like:

    /**
    * Filter to add plugins to the TOC list.
    *
    * @param array TOC plugins.
    */
    add_filter( 'rank_math/researches/toc_plugins', function( $toc_plugins ) {
    $toc_plugins['tocpack-premium/tocpack.php'] = 'Tocpack Premium';
    return $toc_plugins;
    });

    Looking forward to helping you. Thank you.

    ​​​​​​​

    Hello,

    Since we did not hear back from you for 15 days, we are assuming that you found the solution. We are closing this support ticket.

    If you still need assistance or any other help, please feel free to open a new support ticket, and we will be more than happy to assist.

    Thank you.

Viewing 2 replies - 1 through 2 (of 2 total)

The ticket ‘Table Of Content Plugin’ is closed to new replies.