XWiki Syntax 2.1: Macros

2.0 Macros

There is only one kind of macro in XWiki Syntax 2.1, which is called by the syntax: {{macroname param1="value1" ... paramN="valueN"}}...{{/macroname}}. For macros without content there's a short notation: {{macroname param1="value1" ... paramN="valueN"/}}

FeatureXWiki Syntax 2.1Result
Rendering Macro with a content
{{code language="java"}}
System.out.println("Hello World!");
{{/code}}
System.out.println("Hello World!");
Rendering Macro without content

{{include reference="Space.Page"/}}

The referenced page is included in the current page

For the full list of available macros check the Extensions wiki.

Macros in this wiki

IdNameCategoryDescriptionVisibility
tocTable Of ContentsNavigationGenerates a Table Of Contents.Global
viewpptView PptcontentView Office Powepoint documents.Global
exampleExampleFormattingShows an example and its source code.Current Wiki
mentionUser MentionNotificationsInserts a user mention.Current Wiki
anchorAnchor MacroConfluence Anchor macro bridge to the XWiki Id macroGlobal
userListUser listDisplays a custom list of users with their avatarGlobal
asyncAsyncContentAsynchronous and cached execution of wiki content.Global
spaceindexSpace IndexDeprecatedLists documents in a space.Current Wiki
excerptExcerptcontentBridge for the Confluence Excerpt macro. It marks part of the page's content for use by other macros.Global
spacesSpacesDeprecatedDisplays all the spaces in this wiki.Current Wiki
errorError MessageFormattingDisplays an error message note.Global
attachmentGalleryPickerAttachment PickerDevelopmentGrid based attachment picker.Global
warningWarning MessageFormattingDisplays a warning message note.Global
workspacesWorkspacesDeprecatedDeprecated macro that should not be used, here for compatibility reason. Please use the "wikis" macro instead.Current Wiki
contextContextDevelopmentExecutes content in the context of the passed documentGlobal
drawioDrawioBridge between the Confluence Drawio macro and the XWiki Diagram macro. By default it displays the PNG file used by Drawio to preview the diagram. The user has the option to convert the Drawio diagram into an XWiki Diagram for being able to modify it.Global
liveDataLive DataContentDisplay dynamic lists of data.Global
rssRSSContentOutput latest feed entries from a RSS feed.Global
successSuccess MessageFormattingDisplays a success message note.Global
templateTemplateDevelopmentInsert a template.Global
chartChartContentDisplays a graphical chart generated from miscellaneous data sourcesGlobal
notificationsAutoWatchPreferencesNotifications Auto Watch PreferencesNotificationsCurrent Wiki
panelPanel MacrocontentDisplay a panel with stylesGlobal
containerContainerLayoutA macro to enclose multiple groups and add decoration, such as layout.Global
layout-sectionLayout Section MacrocontentGlobal
content-report-tableContent Report Table MacrocontentProvides a content report in table format, based on labels.Global
pythonPythonDevelopmentExecutes a python script.Global
layoutLayout MacrocontentGlobal
scriptScriptDevelopmentExecute script in provided script language.Global
useravatarUser AvatarContentAllows displaying the avatar for a specific user.Global
dashboardDashboardLayoutA macro to define a dashboard.Global
uiextensionsUI ExtensionsDevelopmentInsert UI extensions.Global
wikisWikisNavigationList all wikisCurrent Wiki
cacheCacheDevelopmentCaches content.Global
notificationsCustomFiltersPreferencesNotifications Custom Filters PreferencesNotificationsDisplay the preferences of the given user about custom notification filters.Current Wiki
jobJobDevelopmentExecute the macro content asynchronously and display progress.Global
paste-code-macroPaste Code MacroBridge between the Confluence Paste Code macro and the XWiki Code macro.Global
notificationsFiltersPreferencesNotifications Filters Preferences (deprecated)NotificationsDisplay the preferences of the current user about notification filters.
This macro is now deprecated in favor of Custom Notifications Filters Preferences or System Notifications Filters Preferences.
Current Wiki
buttonButtonInsert a button!Global
notificationsNotificationsNotificationsCurrent Wiki
velocityVelocityDevelopmentExecutes a Velocity script.Global
pdfviewerPDF ViewerView PDF attachments inside wiki pages without downloading or importing them.Global
statusStatusInsert a colored label in the text to highlight the status of an item.Global
wikimacroparameterWikiMacro ParameterDevelopmentDisplay editable parameter of a wikimacro.Global
codeCodeFormattingHighlights code snippets of various programming languagesGlobal
view-fileView FilescontentShow files using PDF Viewer Macro or Office ViewerGlobal
idIdNavigationAllows putting a reference/location in a page. In HTML for example this is called an Anchor. It allows pointing to that location, for example in links.Global
includeIncludeContentInclude other pages into the current page.Global
expandExpandAdd the Expand macro to your page to provide content in an expandable / collapsible section. 

This is one of Confluence's most popular macros. It's great for: visually reducing the amount of information on a page, breaking process information down into clickable steps, hiding background or obsolete information, while still keeping it on the page for future reference.

The macro is collapsed by default, people need to click each one to expand it. There's no way to expand all macros on a page at once, however all Expand macros are automatically expanded when you print or export the page to PDF.|Global

iconPickerIcon PickerDevelopmentSelect an icon within the XWiki icon set.Current Wiki
formulaFormulaContentDisplays a mathematical formula.Global
wikimacrocontentWikiMacro ContentDevelopmentDisplay editable content of a wikimacro.Global
confluence_attachmentsAttachmentsConfluence attachment macro support for XWikiGlobal
boxBoxFormattingDraw a box around provided content.Global
viewpdfView PdfcontentView Pdf documents.Global
sectionSectioncontentGlobal
messageSenderMessage SenderSocialA control that allows users to enter messages that are handled by the MessageStream module.Current Wiki
columnColumnGlobal
childrenChildrenNavigationDisplays a tree of children pages of the current pageCurrent Wiki
noteNoteWrite a note.Global
displayDisplayContentDisplay other pages into the current page.Global
translationTranslationContentDisplay a translation message.Global
multimediaMultimedia MacrocontentBridge for the Confluence Multimedia macro.Global
infoInfo MessageFormattingDisplays an info message note.Global
treeTreeNavigationDisplays a tree hierarchy defined by the macro content or the source parameter.Current Wiki
documentTreeDocument TreeNavigationDisplays the tree of XWiki documents.Current Wiki
net-presago-stream-macroMicrosoft Stream Confluence BridgeContentBridge for the Confluence Microsoft Stream Macro.Global
notificationsEmailPreferencesNotifications Email PreferencesNotificationsDisplay the preferences of the current user about notification emails.Current Wiki
tagcloudTag CloudContentDisplays the cloud of tags in this wiki or in the specified space, if any.Current Wiki
activityActivity (legacy)NotificationsProvide a macro implemented with the Notifications Application to keep a backward compatibility with Activity Stream.Current Wiki
commentCommentDevelopmentAllows putting comments in the source content. This macro doesn't output anything.Global
htmlHTMLDevelopmentInserts HTML or XHTML code into the page.Global
contentContentContentAllows writing content in any wiki markupGlobal
viewdocView DoccontentView Office Word documents.Global
officeOffice Document ViewerContentView office attachments (doc, ppt, xls, odt, odp, ods etc.) inside wiki pages without downloading or importing them.Global
galleryGalleryLayoutDisplays the images found in the provided content using a slide-show view.Global
layout-cellLayout Cell MacrocontentGlobal
uiextensionUI ExtensionsDevelopmentInsert a UI extension.Global
notificationsSystemFiltersPreferencesNotifications System Filters PreferencesNotificationsDisplay the preferences of the given user about system notification filters.Current Wiki
recently-updatedRecently UpdatedconfluenceAdd the Recently Updated macro to a page to show a list of pages, blogs, files, and comments that have been created or edited recently. This is great for project landing, information pages, or team space home pages. It's very flexible, you can limit the list to specific people, spaces, types of content, and more.Global
putFootnotesPut FootnoteContentDisplays the footnotes defined so far. If missing, all footnotes are displayed by default at the end of the page.Global
attachmentSelectorAttachment SelectorDevelopmentA control to be used for object properties of the current document that are supposed to contain the name of an attachment from the current (or target) document. Allows uploading new attachments, and deleting attachments from the target document.  If no target document is specified, the current document will be used. Object properties are only saved to the current document.Current Wiki
notificationsApplicationsPreferencesNotifications Applications PreferencesNotificationsDisplay the preferences of the current user about notification applications.Current Wiki
menuMenuNavigationDisplays a menu created using simple wiki syntax (nested lists and links).Global
jobprogressJob ProgressInternalProvide a UI to follow asynchronous job progressionCurrent Wiki
wireframeBalsamiq WireframeBridge for the Confluence Balsamiq macro. It only displays the image preview of the wireframe. Global
gliffyGliffyBridge between the Confluence Gliffy macro and the XWiki Diagram macro. By default it displays the PNG file used by Gliffy to preview the diagram. The user has the option to convert the Gliffy diagram into an XWiki Diagram for being able to modify it.Global
viewxlsView XlscontentView Office Excel documents.Global
documentsDocumentsContentDisplays a list of documents in a LivetableCurrent Wiki
teamTeamcontentThis macro displays the team members which have a specific tagGlobal
msStreamMicrosoft StreamContentEmbed a Microsoft Stream video in a page by simply passing the URL and any customization parameters.Global
groovyGroovyDevelopmentExecute a groovy script.Global
footnoteFootnoteContentGenerates a footnote to display at the end of the page.Global
userlisterUser ListerThis macro displays the members of the given group(s).Global
jwplayerJW PlayerContentThe JW Player is an open-source embeddable media player for web sites, supporting many commonly-used audio and video formats. The player is easy to configure, customize and extend.Current Wiki
userProfileUser profileDisplays a user profile with custom set of propertiesGlobal
confluence_galleryConfluence Gallery contentBridge for the Confluence gallery macro.Global
tipTipGlobal
mockupMockupBridge for the Confluence Balsamiq macro. It only displays the image preview of the mockup. Global
Tags:
Created by Sascha Hoppe on 2023/07/06 10:42