Is there a way to use texts based on the user language when creating buttons in macros

For example when using the create-from-template macro, can I enter the value of the 'Button text' parameter based on the current users UI language?

Or asking another way:

How can I localize the 'Button text' parameter for the create-from-template macro so that the user will see the buttons' text in his language when visiting the corresponding page?

1 answer

Hi Rainer,

yes, there are a couple of ways to do this. The Tutorial on internationalisation is a good point to start. It is also possible to use this for JavaScript (AJS.I18n.getText(...)) or soy templates (add transformer to web resources).

Best regards,

Hi Robert,

thanks for your answer. Since the macro in question is a built-in macro, I doubt I can change its implementation in regard to internationalization. I was looking more for a method like that which is documented for the 'template name' parameter. To refer to the current date there one use the at notation: @currentDate.

I guess what I am looking for is a way to access a text already defined in the confluence language pack. I would assume a language pack contains a text for 'Create' or 'Create page' which has already been translated. If there were a handle for such texts then I could refer to them when filling out macro parameters.

Example @i18n:createPage.

Best regards


In that case you can create a translation pack. To find out which keys to translate you can add "?i18ntranslate=on" to the end of the url. This should show you the i18n keys, instead of the localized labels.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Feb 06, 2019 in Confluence

Try out the new editing experience

Hi team, I’m Avinoam, a product manager on Confluence Cloud, and today I’m really excited to let the Community know that all customers can now try out the new editing experience and see some of the ...

821 views 40 5
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you