In long pieces of content, including a table of contents that links to locations within the same document can be helpful. Alternatively, you may want to link to a specific section of an article from a link outside that content. While the WYSIWYG editor does not provide an explicit tool for setting up and referencing these anchor points, it can be done with a combination of using Code View and inserting links.
Sections in this article:
Who can do this?
- Enterprise administrators
- Workplace administrators
- Space administrators
- Members of the digital workplace with Write, Edit or Full access
Link to a specific location in content
Creating a link to a specific location involves adding an identifier to the location you want to link to and then referencing that location using a link. Setting up these links is something that you can do after you have written your article. Section headers or titles are ideal locations to act as a reference.
Apply an ID to a destination
While you are editing your content in the WYSIWYG Editor:
- Select the header or title that you want to link to.
- While maintaining this selection, select
More Misc and then
Code View. Your selected text will remain selected in Code View.
- HTML tags surround the selected text. In the screenshot above, these tags are <h2> </h2>, which indicates that this text is a second-level heading. Add
id="description"within the first tag, where the description should be a brief identifier for this location. This example usesid="jobSatisfaction".
Create a link to a destination ID inside the same content
- Select the text or image from which you want to link.
- While maintaining this selection, select
Insert Link. In URL, enter the ID of the location you want to navigate to, preceded by #. For example,
#jobSatisfaction. - Select Insert.
Create a link to a destination ID in another piece of content
- Copy the relative URL of the content you want to link to and append the location's ID in that content, preceded by #. For example, the relative URL linking to
#jobSecuritywould appear as:https://{your digital workplace}/HR/ProfessionalDevelopment#jobSatisfaction - In the content that you want to link from, select
Insert Link. In URL, enter the URL from Step 1.
- Select Insert.