Possibility To Change The Title In TOC
Description
Now, I would really like to have the possibility to change the text in TOC — right now the title is Table of Contents and that's it! But my site is not in English, so it is really ugly to have everything written in Serbian and in Cyrillic, except this one… If there is a possibility to change the title in Bibliography and in Footnotes, why not add the same possibility to TOC? I would really like to be able to do this:
[[toc title="textofmyownchoice"]]
as there is a possibility here:
[[bibliography title="textofmyownchoice"]]
or
[[footnoteblock title="trextofmyownchoice"]]
or
title="" if I don't want to have anything written.
Comments
I most definitely second that!
I second that, too!!
The [[toc]] parsing code already accepts [[toc attributes]], but the rendering code simply ignores them.
One of you two forgot to vote….
I voted… .. :)
Thank you, Helmuti! :)
Not only in TOCs but everywhere a English message is produced by a module or whatever.
With "textofmyownchoice" reduced to " " or "", one can make it not appear at all.
Indeed , the [[module Comments]] already accepts this syntax.
Nope, TOC does not accept this. I think that it is the only module that stays as it is. I tried many times, and I have just tried it again, after reading your message. TOC stays in English… BTW, not only the title should be changed, but also the "fold/unfold" word…
this is already possible with custom CSS and the include system:
Make a new page, perhaps called TOC.
On this page, put a [[toc]] inside a div (give the div a class name, like "tocdiv").
Using CSS, remove the div.title (in tocdiv) with display:none. The same can be done with the fold/unfold if you don't want it. Use FireFox Web Developer to get the precise CSS names.
Here's what the TOC page should look like:
Now to insert a table of contents on any page, simply type: [[include toc title=MyCustomTitle]]