any variable like $currentuser can be used within "Title" Value

This question is in reference to Atlassian Documentation: Create from Template Macro

 

any variable like $currentuser can be used within "Title" Value like $currentDate

2 answers

0 vote
Joseph Clark Atlassian Team Jan 08, 2016

This documentation should help you:

https://developer.atlassian.com/confdev/development-resources/confluence-architecture/confluence-internals/velocity-template-overview/confluence-objects-accessible-from-velocity

The current user is available in a variable called $remoteUser. To get the current date, you can use $dateFormatter.currentDate

 

 

Hello Joseph,

in our company we're trying to make the entry to confluence as easy as possible. To do so, we created a template that allows users to follow certain steps, when starting to wright content into confluence. We thought, it would be nice, if users don't need to type their names and the current date. Unfortunatly the variables you suggested do not work ($remoteUser and §dateFormatter.currentDate). Additionally we would like to have a certain field called "title" to automatically put whats typed here as page title. Is their any way to do that? Thanks in advance!

 

Nadja

Hi,

If you like to used standard confluence pages as templates or blueprints and use different kind of variables in a simple way (e.g. __Current_User__, __Current_date__, __Template_Version__), then you should have a look at our plugin Page Tree Creator.

Marketplace Link : Page Tree Creator

Regards,
Stephan

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Kesha Thillainayagam
Posted Apr 13, 2018 in Confluence

We want to hear how your non-technical teams are using Confluence!

Hi Community! Kesha (kay-sha) from the Confluence marketing team here! Can you share stories with us on how your non-technical (think Marketing, Sales, HR, legal, etc.) teams are using Confluen...

2,087 views 25 10
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