Using Links to Create Pages from Confluence Templates

Scenario

You might want to guide users in creating content in Confluence, by providing a one-click link to create a page with a structured layout by:

  • Automatically use a Confluence template as the base structure.
  • Automatically suggest a page title
  • Automatically categorize a page under a parent page
  • Automatically add labels to the page

You may also apply this to Scaffolding Live Templates. See Using Links to Create Pages from Live Templates. (Only applicable for Server version.)


Result


Recipe

Ingredients

Add-ons

Platform

Server, Data Center

Level

EASY

Estimated time

5 minutes

Macros

Suppliers

Storage format

Macro structure

You can recreate the example in the editor view:

Steps

  1. Create an Add Page macro.

  2. For the parameter Link Text, enter the title of the link e.g. "Create a new Product". Users will see this text when viewing the link on the page.

  3. To decide what will happen when a user clicks on the link, specify the source parameters:

    1. Source parameter determines the name of the Confluence template to use. E.g. "Product template".
    2. Source type is set to "template" since it is based on a Confluence template.

  4. If you need to add a little bit of standard in page titles, make use of Prefix and Postfix parameters. In this example, we add "Product - " as postfix, so all page titles will start with "Product - (Name of Product)".

  5. To ensure organized space, make use of the Parent parameter, which tells Linking where to create the page. Useful to automatically categorize the pages.

  6. To automatically add label to the pages, we specify "product" for Labels parameter.