You can quickly create a table of contents (or other in-page links) by associating anchors to selected headings (or text) and then linking to those anchors.
Lengthy articles that contain a table of contents (TOC) with links are easier to scan and easier to navigate using adaptive technology. Unless the article is short, if it has two or more headings, include a TOC in the form of a bulleted list.
Most of the time you will not need to create TOC links to subheadings below H2 unless you have a lengthy and complex article. Even then, you should use your judgment as to whether or not it made sense.
Note: To meet accessibility standards:
- Identify any in-page links as such, e.g. (on this page). You do not have to identify TOC links as "(on this page)."
- Create link text that matches or closely matches the text of the location you are linking to.
In this article:
Making In-Page Links
Before you can create an in-page link, you have to create an anchor.
Making an Anchor
- Before you create any anchors, Remove the Extra HTML Formatting from an Article. Otherwise, you will have to reset them.
Assuming you are in edit mode:
- Find the text you want to create an anchor for.
- Place your cursor at the beginning of the text.
- Do not highlight the entire text when creating the Anchor link. If the entire text is highlighted then the Anchor link will look like a broken link. Placing the cursor at the beginning of the text will add the Anchor flag and keep the text as is.
- Click the Anchor icon.
- Enter a name for the anchor.
- Note: Anchor Names cannot contain spaces. If you want to use multiple words for a name, use a hyphen or underscore.
- Click OK.
Linking to an Anchor
- Select the text that you want to link to the anchor.
- The link text should match or closely match the anchor text.
- Select the Link icon.
- Displayed Text is filled in with your selection; you can change it and the text in the Body will update.
- Change the Link Type to Link to anchor in the text.
- Select an Anchor by Anchor Name.
- Anchor Names cannot contain spaces. Separate multiple words using a hyphen or underscore.
- Anchor Names cannot contain spaces. Separate multiple words using a hyphen or underscore.
- Click OK.
- Type (on this page) next to the link you just created unless it is in the TOC.
If you need to remove an anchor, you can just backspace.