This plugin automatically generates a Table Of Contents for any page. HTML heading tags are extracted and listed in a tree. The page body is modified to include anchors between the TOC and the headings.
Simply upload the plugin folder to your /plugins directory and enable the plugin in your Administration panel.
The plugin has one configurable setting. You can configure the HTML tags that should be included in the TOC. Default value is h2,h3.
This extension can also be found on Github. If you want to improve it, extend upon it or add a localisation, please feel free to fork it.
Bedankt: 74 tijden
I get the following error on the pages themselves:
Deprecated: Call-time pass-by-reference has been deprecated in /home/www/site/test/plugins/autotoc/autotoc.page.tags.php on line 68
And I can't update the configuration in the admin panel, it returns 'invalid URL'.
Any idea?
Bedankt: 52 tijden
Ok the deprecation error can be fixed by changing &$text to $text on line 68 in autotoc.page.tags.php.
The config thing must be a bug in the Cotonti admin area, because it uses the regular extension config method (in the setup file).
Bedankt: 181 tijden
See also renewed version here