Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
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

Macro / User Macro copy page button

Hello Community,

I would like to have a macro that copies the current page and pastes it under the current page. 

Ideally, you can give it a date and a number in a popup menu beforehand, which will automatically generate the title.

It is not possible for us to simply use a blueprint for this, because there will be constant changes to the mother page, by several users.

Do you know a macro that can do this, or can you help me to create a user macro?

Kind Regards Alex

1 answer

0 votes
Bill Bailey Community Leader Nov 30, 2021

Well I can help you with the capability question, but writing one is a bit complex. THe first thing to understand is that user macros are generally server side, and are rendered when a page is rendered. BUT you do have the option of including Javascript that can be run client side (via a page on the button).

Then via REST calls you can do what you want. I have a macro that something similar in that it renders a button, that when pressed generates a PDF, cleeans a file name, writes that file as an attachement to another Confluence page, and even shots a copy to our website. 

Because my user macro skills are limited to Velocity and CSS knowledge, I had to get outside help on the script. ;-)

Thank you for offering help! I will solve my problem differently. Thank you! :)

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
TAGS
Community showcase
Published in Confluence Cloud

🏠 Say hello to the new Confluence Home!

Hi Atlassian Community, My name is DJ Chung, and I’m a Product Manager on the Confluence Cloud team. Today, I’m excited to share a new and improved version of Home. The new Home helps you ...

1,026 views 8 42
Read article

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