Excerpt Macro

The Excerpt macro is used to mark a part of a page's content for re-use. Defining an excerpt enables other macros, such as the Excerpt Include and Blog Posts macros, to display the marked content elsewhere.

You can only define one excerpt per page. In other words, you can only add the Excerpt macro once to a page.

Using the Excerpt Macro

To add the Excerpt macro to a page:

  1. From the editor toolbar, choose Insert > Other Macros
  2. Find and select the required macro

Speed it up with autocomplete: Type and the beginning of the macro name, to see a list of suggested macros. In this example we're inserting the cheese macro.

To edit an existing macro: Click the macro placeholder and choose Edit. This will open the macro details, so you can edit the macro parameters.

To add reusable content to the macro:

  1. Add your content inside the Excerpt macro placeholder.
  2. Choose the macro placeholder to see the options panel, and select the option to Display on new line or to Display inline. The default is to display the content of the macro on a new line. If you choose the inline option, the content of the macro will form part of the same paragraph as the text preceding and following it. Note that this option affects only the page that contains the Excerpt macro. It does not affect any pages where the content is reused.

Screenshot: The Excerpt macro placeholder and options panel

 

  1. New line
  2. Inline

Parameters

Parameters are options that you can set to control the content or format of the macro output. Where the parameter name used in Confluence storage format or wikimarkup is different to the label used in the macro browser, it will be listed below in brackets (example).

Parameter

Default

Description

Hide Excerpted Content
(hidden

false

Controls whether the page content contained in the Excerpt macro placeholder is displayed on the page.

Note that this option affects only the page that contains the Excerpt macro. It does not affect any pages where the content is reused.

Wiki markup example

This example is useful when you want to add a macro outside the editor, for example as custom content in the sidebar, header or footer of a space.

Macro name: excerpt

Macro body: Accepts rich text.

{excerpt:hidden=true|atlassian-macro-output-type=BLOCK}
This is the *text* I want to reuse in other pages. This text is inside an Excerpt macro.
{excerpt}
Last modified on Dec 12, 2019

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.