Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Issue using Content by Label Macro

Rob St-Germain June 10, 2020

here are the facts:
- I have two confluence pages: DOC and LIST.
- I have a pdf document called PDF1 in Confluence DOC page.
- I added label called L1 to the pdf document PDF1 in the Confluence DOC page.
- Confluence DOC page itself has no labels.
- In the Content by Label Macro editor, I insert the L1 label in Confluence LIST page.
- the Content by Label Macro preview shows the link format as "Confluence DOC page > PDF1".
- There are no checks in the check boxes for "show labels for each page" and "show space name for each page".
- I would like the link format to be just "PDF1" and omit the page name. Help !

2 answers

1 accepted

0 votes
Answer accepted
Maltavius June 11, 2020

Content by Label macro links to Pages, it is what it does.

Have you tried checking "Exclude current page", that might remove the link entirely.

 

Not sure what you are after, but does the Attachments Macro do what you want?

Rob St-Germain June 11, 2020

Thanks, but there is no checkbox option for "Exclude current page" in the Content by Label macro in the cloud version of Confluence. Also I don't see an Attachments macro in the cloud version of Confluence. 

1 vote
Shannon S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 15, 2020

Hello Rob,

Thank you for raising this, and I hope you are well!

As @Maltavius mentioned, the Content by Label macro will always display the name of the page which contains the attachment first, so your users know where to find the specific attachment.

For you, the Attachments Macro is the best route, and I can confirm that this macro is currently available in Confluence Cloud. You can review how to add it to a page by following the documentation on inserting the Attachments macro

Regarding the feature to exclude the current page, this is a newer feature in Confluence Server, and it hasn't been added to Confluence Cloud at this time. The Server version of this request has since been closed, but you can find the open Cloud request below:

  • CONFCLOUD-5245 Option to exclude current page in results when using contentbylabel macro

If you're ever looking to exclude a page in the future, there's a workaround provided by a customer in the comments:

For those who don't know, the most viable workaround, which I called "negation of the page title" above, is to set the "With title" filter to have a value of !"Your Page Title Here"

I understand that it's not ideal, since the page name can still be changed, but it should work in a pinch.

Let me know if you have any trouble with the Attachments macro; I'm happy to help.

Regards,

Shannon

Dennis T September 4, 2020

@Shannon S, the workaround doesn’t function any more on Cloud.

That goes for all flavors of it, i.e., !"Current Page Title", -Current+Page+Title, !Current+Page+Title, -"Current Page Title". This is why people hate Atlassian. The workaround gets nixed but the issue doesn’t get fixed. Make sure you don’t affect workarounds if you’re not going to fix the issue being worked around. Ugh.

Like # people like this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events