It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Confluence Smart Numbered headings as Anchors

We currently have a huge document (200 a4 pages) which is created of sub pages inside a numbered headings macro:

23-11-2018 14-02-37.png

Which numbers fine.  But the users would like to be able to setup links in the format
See Section 4.1.1

Where the text See Section 4.1.1 is a hyperlink to a header on another page.  
They need to be able to keep the link and text up to date automatically  - so that if we added a new page it might automatically renumber the heading to 5.1.1 and the link text changes to See Section 5.1.1

Do any plugins do this?  Can it be done with Scriptrunner?

2 answers

0 votes
Daniel Eads Atlassian Team Nov 28, 2018

Hi Chris,

Have a look at the Anchor macro. Even when the heading numbers change in Numbered Headings, the anchor tags will be immutable. The anchor tag will need to be placed on all the pages you're including where the headers are at.

When you're linking to the anchors, you just need to make sure the link is for the page you're doing all the includes on. The anchor will be something like <confluencespace>/page#anchor where the anchor comes after the hash symbol. The anchor should come across from the included page onto your large page. You'll also need to make sure the anchors are unique across all the included pages so that the user's browser doesn't get confused trying to locate the anchor tag.



Were you able to find an answer to this - whilst the linking does work - the anchors are not dynamic, and therefore are not able to reference any changes in the source document...



Suggest an answer

Log in or Sign up to answer
Community showcase
Posted in Confluence

Lessons and Learnings: Six Months of Working Remote [Discussion]

Hey there, folks! For most of us, the past six months- yes, you read that right- have been a journey. More people than ever before have pivoted to working remotely, and navigating being on-scre...

4,120 views 4 6
Join discussion

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you