Anchor creation instructions incorrect: DO NOT use a space between words.

Reid Manchester April 4, 2016

This question is in reference to Atlassian Documentation: Anchors

After two years of fighting the anchor macro it seems that removing spaces from the anchor name during creation is the key to success.

2 answers

0 votes
Reid Manchester April 12, 2016

I assure you, entering a space in the anchor name does NOT work in our installed instance, version 5.9.1

Others in the forum appear to have the same experience.

Rachel Robins
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
April 13, 2016

I have raised a bug for this here https://jira.atlassian.com/browse/CONF-41385  

It would be fantastic if you could comment on the issue and provide an example of the type of link you're using (how you add the link - URL, Advanced tab etc). 

I was not able to replicate your issue in Confluence Cloud, so may be specific to Confluence Server perhaps.  

0 votes
Rachel Robins
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
April 11, 2016

Hi Reid, Confluence can successfully link to anchors that have spaces in the anchor name.

I find the most effective way to link to an anchor is to use the Advanced tab in the Link dialog.  There you can enter the following examples to link to an anchor anywhere in your site:

#anchor title
Page Title#anchor title
SPACEKEY:Page Title#anchor title

All three of these examples work (in order they are: same page, another page, page in another space).  

Where it gets tricky is when you are linking from an external site, and need to construct a full URL. This is where Confluence would automatically remove the spaces for you, so you end up with a URL that looks like this:

yoursite.atlassian.net/display/SPACEKEY/Page+Title#pagetitle-anchortitle

Note that the page title is actually repeated in the URL, and the anchor name has spaces removed. 

What I've seen many people do in the past is to add a link to the anchor on the same page, and then copy the URL when viewing the page to make sure they get the correctly rendered URL. 

Hope this helps

 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events