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

Best way to handle repetitive, formatted blocks of same text?

David Sidwell March 24, 2013

Hi Sarah and everyone else.

Kicking some nice (6 point) goals with Confluence :-)

If we want to have the same formatted text over and over again, what would be the best way? I started teaching myself macros, but the user permissions needed made our sys admins shudder. But I've got temp access.

Anyway, picture a Tip macro with everything pre-filled in and the user should have nothing to select, except the Macro from the list. And then it shows the nice green box with the fixed text "You should back up this file before editing, then restart the server after you have..." etc.

update: should add, I've dived into Storage Formats already so am comfortable with that level of answer.

4 answers

0 votes
Milo Test
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.
July 30, 2015

You could make a page of just the tip, then use the Include Page macro everywhere you want to add that tip. The added advantage is that like the macro, you can modify the Tip page and all the pages that use it will be automatically updated, and you don't need special privileges to do the page->Include Page method.

0 votes
David Sidwell April 9, 2013

Hi all. Thanks for the answers. I ended up creating a User Macro (as a test) that invoked the existing Tip Macro, with some values pre-filled in. It works, but needs fine tuning (see notes at end)

## @noparams
  
<ac:macro ac:name="tip">
<ac:rich-text-body>
<p>You should take a back up copy of this file before editing it</p>
</ac:rich-text-body>
</ac:macro>

Notes

It's not exactly complex, but it works as proof of concept. Gave it a Name and Title, plus Category = Confluence Content and Macro Body Processing = Rendered

User sees text "You should take..." in the Preview (when adding the Macro to the Page) but NOT after the Macro added to the Page. Again, I'm sure some tinkering could get around this.

Anyway might help someone else.

0 votes
RianA
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.
March 24, 2013

I guess you would find Page template in handy if you use same format over and over again. You could even put some macro in there.

0 votes
BernardoA
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.
March 24, 2013

Hello,

Actually, since version 4.0 is quite simple to have and use the same formatted text, so basically is necessary jut copy and paste the text and you'll have the same foramtted text, because in current versions the application copies as invisible markup so that's the reason you can simply copy the formatted text just doing Ctrl+c and Ctrl+V to another page.

Please try this and feel free to ask!

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events