Populate a list with Confluence pages

Populate a list with Confluence pages

This article demonstrates how to dynamically populate a dropdown list with Confluence pages created as child pages of a specified parent page.

One advantage is that the list automatically grows or shrinks based on the available content.

Ingredients

Apps

Scaffolding

Macros

Content Options, List Data

Guide

  1. Create a table as in the following image:

  1. Insert Date Data macros as shown in the Start Date and End Date columns.

  1. Set the Date Data macro names to startint and endint.

  2. Insert a List Data macro in the Tutorials Selected column.

  3. Set the List Data macro name to ScafTutorials and select the Allow Multiple checkbox.

  4. Insert a Content Options macro into the List Data macro.

  5. In the Insert ‘Content Options’ macro dialog, set the Space(s) and the Parent parameters.

For this example, enter the current space, SCAF, and the Basic Tutorials page located in that space in Parent.

  1. Click Insert and publish the page.

  2. Click Edit Contents to enter your data.

A list of Confluence pages appears in the dropdown menu in the Tutorials Selected column.

You can press Ctrl to select multiple options.

Notes

For the Parent parameter:

  • If the parent/ancestor is in the same space, you can either enter just the page title or the space key followed by the page title.

  • If the parent/ancestor is in a different space, enter the space key followed by the page title. For example: <SPACE>:<Page Title>.

You may experience performance issues with Content Options. Use sparingly.

Result