The Confluence XHTML Syntax is what Confluence currently uses to store the content of its pages. It is what you can see:
- when using the "View Storage Format" feature of Confluence
- in BodyContent objects with a a bodyType equal to 2.
The Confluence XHTML Syntax is basically XHTML (the XML variant of HTML), with a few additional, Confluence-specific tags and attributes, and a few oddities.
WarningThe Confluence XHTML Syntax is an XML dialect that can contain CDATA sections. When stored in a CDATA section in the content property of BodyContent objects, a space is added to CDATA end tag. ]]> becomes ]] >. You will have to pre-process this before parsing the Confluence XML syntax.
InformationWe've not seen this syntax ever indented in Confluence exports. If you see indented example, they were either indented by ourselves for readability, or taken from the Confluence "View Storage Format" feature.
WarningSometimes, block macros are put inside their own #<p># element. But not always. This can surprising, and this need to be carefully handled while parsing or converting the Confluence XHTML syntax.
WarningConversely, we have seen inline macros defined by Confluence plugins that are put inside their own #<p># element. We don't know how to handle this and they will appear on their own line (after import) in XWiki.