Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Is it possible to set a variable to be used later in the page?

Bas H
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 12, 2024

We've got a lot of Confluence pages that contain runbooks. These runbooks contain code sections we need to copy/paste.

I'd like a text field at the top of the page, which an end user can fill. The text in this field should then be used to populate the variables inside code snippets later on the page, which now manually have to be edited after copy/pasting, which sometimes leads to errors. 

 

I wonder if there's an existing plugin that does this, lr get some pointers on how we could get this to work. 

1 answer

0 votes
Benjamin
Community Champion
January 12, 2024

Hi @Bas H ,

 

If the code text is in a code block then probably not. You maybe able to look into using variables.

https://confluence.atlassian.com/doc/create-a-template-296093779.html#CreateaTemplate-Templatevariables

 

IF you are using code blocks, it might be worth looking a code blocks type of apps int he marketplace. 

 

https://marketplace.atlassian.com/search?hosting=server&query=code%20block

 

Hope this helps.

Brian Bolt
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
April 12, 2024

I think something like this is the goal.  https://cloud.google.com/dataproc/docs/guides/create-cluster#creating_a_cloud_dataproc_cluster

 

Being able to create simple variables and use them throughout the page would be great.  Do you know of any specific market place or build in features for this?  A bonus would be able to set them via URL params so we can direct people to a page with as a pre-filled tempted page.

Screenshot 2024-04-12 at 9.50.12 AM.png

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events