same page TOC links have wrong URLs (BB-4018)

Issue #3912 resolved
Alexander Sideropoulos
created an issue

The same-page TOC links generated for a sub-directory page are incorrectly prefixed with two directory paths.

For example, the "Subdir/Pagename" content: {{{ <<toc>> = Main heading = == Sub heading == }}}

Would result in these two links with duplicate directory paths: {{{ [[Subdir/Subdir/Pagename#!main-heading]] [[Subdir/Subdir/Pagename#!sub-heading]] }}}

Comments (15)

  1. Anonymous

    In addition, if there are two headings with the same name, the ToC does not disambiguate them. If you click a link for the later ones, you are taken to the anchor tag for the first one.

  2. Log in to comment