Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter mprprojects

    (@mprprojects)

    Ok, I see. Thanks for your reply. For anybody who’s interested, as a temporary fix I did the following:

    • In my post template I added a html anchor “post_navigation” to the navigation block and another anchor “post_comments” to the ‘Comments’ text block.
    • In function generate_toc in file wp-content/plugins/table-of-contents-block/includes/helpers.php I added the following before the return statement (return $toc):
    $toc .= "<ul style=\"list-style-type: none;\">";        $toc .= "<li><a href=\"#post_navigation\">Post Navigation</a></li>";
    $toc .= "<li><a href=\"#post_comments\">Comments</a></li>";
    $toc .= "<li><a href=\"#respond\">Create Comment</a></li>";
    $toc .= "</ul>";

    That works fine for my purpose.

    Thread Starter mprprojects

    (@mprprojects)

    I added the following css code to get it to work:

    body * {
      scroll-margin-top: 50px
     }
Viewing 2 replies - 1 through 2 (of 2 total)