This server will be upgraded at 3pm Sydney time on December 3rd (December 2nd, 8pm PST) and will be down for up to 30 minutes.
This documentation relates to an early version of Confluence.
View this page in the current documentation or visit the current documentation home.

Content by Label Macro

All Versions
Click for all versions
Confluence 2.0 User Guide

Index

You need to edit in 'Wiki Markup' mode to include macros in your page.

The Contentbylabel macro lists content associated with specific labels.

Contentbylabel Macro

What you need to type What you will get
{contentbylabel:documentation, my:stuff}
Related Labels Macro (Confluence 2.0) Labels: documentation
Working with Macros (Confluence 2.0) Labels: confluence, macro, list, all, summary, index, documentation
Confluence 2.0 Home (Confluence 2.0) Labels: guide, user, documentation, userguide, favourite, confluence20, contents


By default, Confluence lists all the labels for each result displayed. See optional parameters below to disable this.

Recommended Default Usage

To display all pages with the label needs-fixing, use:

{contentbylabel:needs-fixing|showLabels=false|maxResults=99|showSpace=false}




Optional Parameters

No  parameter Default Description
 1 key all Filter by space
(Note: Keywords @all and @self are available with Confluence 2.2.2 and higher.)
 2 type false Filter by content type
 3 showLabels true Show or hide labels for results
 4 showSpace true Show or hide spaces for results
 5 excerpt false Show or hide excerpts for results
 6 maxResults 5 Specify maximum results to display
 7 sort=creation
sort=title
sort=modified
recent The 'sort' attribute is an optional attribute that allows you to configure how the children are sorted. Use the 'reverse' attribute to optionally reverse the sorting.
 8 operator OR (Confluence 2.5 and higher.) The operator to apply to the supplied lists of labels. By default, a page with any of the labels will be listed. By using operator=AND, only pages with all of the supplied labels will be listed.

1. Filter by space

{contentbylabel:dogs,cats|key=PETS}




2. Show only results in current space (Confluence 2.2.2 and higher)

{contentbylabel:dogs,cats|key=@self}




3. Show results from all spaces (Confluence 2.2.2 and higher)

{contentbylabel:dogs,cats|key=@all}




4. Filter by content type: pages or blog posts

{contentbylabel:dogs,cats|type=page,blogpost}




5. Hide labels for results

{contentbylabel:dogs,cats|showLabels=false}




6. Hide spaces for results

{contentbylabel:dogs,cats|showSpace=false}




7. Display excerpts for results

{contentbylabel:dogs,cats|excerpt=true}




8. Specify the maximum number of results to display

{contentbylabel:dogs,cats|maxResults=99}




9. Sort by creation date, modification date or title

{children|sort=creation|reverse=true}



RELATED TOPICS

Related Labels Macro
Navmap Macro
Recently Used Labels Macro
Working with Labels Overview
Working with Macros

Take me back to Confluence 2.0 Home

Labels

label label Delete
filterbylabel filterbylabel Delete
contentbylabel contentbylabel Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.