/
Table of Contents Shortcode

Table of Contents Shortcode

Summary


The Table of Contents shortcode inserts a linked list of headings from your page.The list is automatically generated, and the titles link to the headings on your page. This can help aid navigation of a longer page with many headings.


Optional Attributes

title

Add a title to your table of contents.

Default: No title

numbered

Set this to "true" to make the list numbered.

Default: false

max_level

Choose how many levels of headings are displayed. Options: 1 (only H2s), 2 (H2 and H3s) or 3 (H2, H3, and H4s).

Default: 3

Set to "true" to add back to top links on H2s.

Default: false

width

Set the percent max width of the table of contents.

Default: 50

container

If you would only like some of the headings on your page to be included in the list, you can use this to specify a jQuery

Please ask the Web Team to help you implement this.

Default: div.entry-content (This is all of the content between the breadcrumbs and the footer.)

inline

Set to 'true' to display the Table of Contents as an un-styled, inline bulleted list. The width will be ignored and the TOC will flow with the content.

Default: false - the TOC will display in a callout.

id

Use this parameter to set the id of the element that contains the table of contents. You must specify unique ids if you want to have more than one Table of Contents on each page.

Default: toc

Usage / Examples

[toc ]

This is all that is needed to add the basic table of contents to your page.

[toc container="div.tocContent" title="Topics"]

Add a list of the headings in the tocContent div with a title of Topics.

Omit Headings

You can omit a heading from the Table of Contents by adding a class="toc-skip" to the header element. You must do this in the Text tab of the editor. For example:

<h4 class="toc-skip">Quamquam</h4>




Related content

Tabs Shortcode
Tabs Shortcode
More like this
Add a Tab or Accordion Menu
Add a Tab or Accordion Menu
More like this
Shortcode Reference
Shortcode Reference
More like this
Template - How-to guide
Template - How-to guide
More like this
Components and Plugins
Components and Plugins
More like this