G'day - thanks for a great module.

Just installed it and tested the back to top links. Unfortunately, the back to top links refer to a anchor that does not exist on the page. Have tried the Filter Configuration options, Back to top anchor with the following options:
toc
header
page
screen
wrapper

In all cases, the back to top links are correctly created, but the target a name is never created.

The only way I've been able to get it to work is to have no value for Back to top anchor.

CommentFileSizeAuthor
#4 tableofcontents.patch857 bytesextect

Comments

AlexisWilke’s picture

Assigned: Unassigned » AlexisWilke
Status: Active » Fixed

This should be fixed in 3.x-dev (available within the next 12h)

I had changed the id into a class. However, you could specify an identifier name in the filter setup and put the table of content tag in a <div>... not practical for customers though!

On my end, I was using the identifier of the content block.

Now, the default name will be "toc". But you can change it with [toc id=other_id;]

Thank you.
Alexis Wilke

agileware’s picture

Thanks Alexis, good one :)

Also forgot to mention (for those Googling this problem) that you can also just change the page.tpl to include the required a name, that's an easy fix.

Happy Drupal'ing!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

extect’s picture

Status: Closed (fixed) » Active
StatusFileSize
new857 bytes

I just updated to 3.x-dev, but the default of 'toc' mentioned in #1 does not work when I am using no options at all by just writing [toc]. There is no id inserted unless I explicitly specify it like this: [toc id=toc;]. The problem is in tableofcontent.pages.inc where

  if (!$options) {
    return;
  }

causes the function to stop before the default has been set. Patch attached.

AlexisWilke’s picture

Status: Active » Fixed

8-)

Good catch. Thank you for the fix! A new -dev will be available in 12h.

Alexis

EllECTRONC’s picture

Version: 6.x-3.x-dev » 6.x-3.4
Status: Fixed » Active

Still no anchor to toc and no id=toc

AlexisWilke’s picture

Version: 6.x-3.4 » 6.x-3.5
Status: Active » Fixed

It will be in 3.5. It was in the -dev.

Thank you.
Alexis Wilke

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.