Runs a projectdoc cleanup on the referenced document.
The projectdoc Toolbox is quite picky when processing property information in a properties table. It assumes that there is only plain text for the property name and the property controls. If an author copies a value from another web page as a property value, this text may contain additional HTML span
or div
elements. These elements are not rendered, but they are considered to be part of the value definition.
This problems can be manually solved using the Confluence Source Code Editor. The author simply needs to remove the extra HTML elements that have been added.
This service supports authors to execute some come cleanup procedures. These include:
- Remove any HTML elements from the property name
- Remove any HTML elements from the property controls
- Remove span, div, and p HTML elements from the property values
- Remove br elements from the property values
Document properties with the preserve control are not cleaned up. So this control enables page authors to override the cleaning process for a particular property.
Parameters
These parameters control the cleaning procedure of a projectdoc document.
id-list
The comma-separated unique identifiers of the projectdoc documents to process.
The properties of these documents are cleaned. This includes the name, the value, and the controls of all properties. If a property is marked with preserve
, this particular property is skipped and not cleaned.
new-version
Flag to control whether a new version should be created. If set to false
, the document is saved without creating a new version. Defaults to true
to create a new version.
include-children
If checked, the process also cleans up the child documents of the specified document.
If this boolean request parameter is set to true
, not only the document specified with the id parameter is cleaned, but also all of its children and their children.
html-elements
The comma-separated HTML tag names to remove from the property values. Defaults to span, div, p
.
Select the names of HTML elements you want to remove here. If you set at least one element, the defaults are no longer taken into account. If you want to add additional elements to the defaults, you need to add the defaults as well.
property-names
The list of comma-separated properties to cleanup. If none is given, all properties are cleaned. Note that properties with the preserve
control are never cleaned.