pdx:removeChapter

Removes a whole chapter from a Word document.

Description

Element definition

This element allows to remove (sub)chapters which corresponding heading contains a certain string of text.

This element finds all headings with the required string of text and removes all contents until one hits a new heading of the same or lower level.

Attributes and sub-elements

src

The path to the source Word document.

target

The path to the resulting Word document.

searchTerm

The string of text that we want to search in the headings.

Code samples
#Example 1

config.xml

content.xml

settings.xml

The resulting Word document looks like: