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

How to display content only in 'edit' mode (and so, not visible in 'read' mode)?

Nicolas Casel
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 10, 2018

(For Confluence version 5.8.18)

I am looking for a way (macro?) to propose this:

in a wiki page, inserting some content that is displayed only in 'edit' mode (indeed, it would be some guidelines about how to manage content in edit mode). But when in 'reading' mode, this content would not be displayed.

Is there a macro that does this kind of job?

Thank you!

7 answers

3 accepted

23 votes
Answer accepted
Michelle Oliveri March 6, 2019

The Page Properties Macro helped me hide content.  

1) Add the Page Properties Macro.

2) Add notes or instructions within the macro box.

3) Check the "Hidden" box within the macro.   

The content within the macro will not show unless you are in Edit mode (as long as the Hidden box is checked).    

Сергей Стальнов December 20, 2021

Great! 

The content within the macro does not appear on the page, but you can find the page with this content using confluence search.

Thanks!

Like # people like this
Scott Beeson
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
December 2, 2022

Not the most elegant solution, but it works!

9 votes
Answer accepted
Christo Mastoroudes [Adaptavist]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 10, 2018

Yes you can do this. 

Use the Confluence Source Editor addon, edit the page, click the "<>" button and put the following code.

<ac:placeholder>This text will only be visible in edit mode
</ac:placeholder>

 

If the answer solves your question please mark it as accepted so that it might benefit other people.

Nicolas Casel
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 11, 2018

Great, it works well! Thank you.

Micheal Planck October 26, 2023

You can also create the placeholder text while editing a template page, then just copy it from the template page and paste it to the regular page. From @Gabriel Points

3 votes
Answer accepted
Greg Jewett July 2, 2021

If anyone still needs this, and your Confluence installation has a "DIV" macro, then you can insert that DIV Macro and modify the property called "Style" and put:  "display: none;"

That will force a CSS style to not display the content in the DIV.

4 votes
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 10, 2018

There's another trick to this if you want to do it without add-ons.

Create a new template, and look carefully for the formatting for guidance or placeholder text.  Create some text and make it that type.

Create a new page from the template, so you end up in edit mode.

Highlight and copy some of the placeholder text.

Paste it into the edit page for the page you want it on and then update the text to what you need there.

Deleted user June 19, 2018

Great! worked for me (though i had to copy whole paragraph which included "instruction text" not just one line)

Brandon Valley May 24, 2020

@Nic Brough -Adaptavist-  what do you mean by "make it that type"?

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 25, 2020

Select the text and change the formatting.

James Gentes January 3, 2022

The icon doesn't exist on normal pages.. it must be a template, and it looks like a piece of paper:

Web capture_3-1-2022_82338_wiki.cfops.it.jpeg

While this solution is a bit convoluted, it does work well once you've copied the instructional text to the new page.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 3, 2022

Yep, that's why I said "create a new template"

Like Brandon Valley likes this
1 vote
Steve Carter May 9, 2022

If you have the HTML macro then you can add it as a bona-fide <!-- HTML comment. --> I have used this for the use-case you described: notes to the updater.  

1 vote
Robert Reiner _smartics_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 10, 2018

This feature is supported by the Section Macro (Hide Parameter).

I assume that this can also be achieved by a user macro and there are probably many macros that allow to hide content (e.g. see here). I'd recommend to check if there is already a macro with a 'hide' feature installed on your Confluence. ;)

The one I provided a link for is part of a free add-on on the Atlassian Marketplace. Please note that I'm one of the authors of this add-on. 

Nicolas Casel
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 11, 2018

Thanks Robert for your feedback.

I cannot find the 'Hide' parameter with the 'Section' macro:

confluence-section-macro.png

Robert Reiner _smartics_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 11, 2018

Thank you for you feedback!

You would need the Section Macro from the Project Documentation Add-on (the name is the same as the one of the Section Macro provided by Confluence).

0 votes
Michael Eskin July 11, 2018

Gliffy seems to be able to render previews in edit mode without image markup in their macro body. Any idea how they accomplish this? Their macro rich-text bodies are empty if you examine the page storage format...

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events