Confluence 5.7 has reached end of life
Check out the [latest version] of the documentation
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.
To add the Excerpt macro to a page:
Speeding up macro entry with autocomplete: Type { and the beginning of the macro name, to see a list of suggested macros. Details are in Using Autocomplete. To edit an existing macro: Click the macro placeholder and choose Edit. A macro dialog window will open, where you can edit the parameters of the macro.
To add reusable content to the macro:
Screenshot: The Excerpt macro placeholder and options panel
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 | 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. |
The following examples are provided for advanced users who want to inspect or edit the underlying markup for a Confluence page.
Macro name: excerpt
Macro body: Accepts rich text.
The following additional parameter is available in storage format and wikimarkup. It performs the same function as the options panel in the editor.
| Parameter name | Required | Default | Parameter description and accepted values |
|---|---|---|---|
atlassian-macro-output-type | No | BLOCK | Determines whether the content of the Excerpt macro body is displayed on a new line or inline. Available values:
Note that this option affects only the page that contains the Excerpt macro. It does not affect any pages where the content is reused. |
<ac:structured-macro ac:name="excerpt">
<ac:parameter ac:name="hidden">true</ac:parameter>
<ac:parameter ac:name="atlassian-macro-output-type">BLOCK</ac:parameter>
<ac:rich-text-body>
<p>This is the <strong>text</strong> I want to reuse in other pages. This text is inside an Excerpt macro.</p>
</ac:rich-text-body>
</ac:structured-macro>
{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}