DTD validator

Description

The DTD validator action verifies if an XML file corresponds to a certain structure or format according to a Document Type Definition or DTD.

Options

Option Description

Action name

The name of the workflow action.

XML File name

The name of the XML file to validate

DTD Intern

Check this if the DTD is contained in the XML file

DTD File name

If the DTD is not internal, specify the DTD file to validate with.

Result

What this action passes on to the next action. See Action results for how results travel through a workflow.

Result Value

True

The XML file is valid against the DTD.

False

The XML file does not follow the DTD: the number of errors is the number of validation errors. The file or the DTD does not exist, DTD Intern is selected and the file has no DOCTYPE, or the file is not well formed: the number of errors is 0.

Result files

Passed on unchanged.

Result rows

Passed on unchanged.

The action reads the DOCTYPE of the file, which Hop refuses by default: the variable XML_ALLOW_DOCTYPE_DECL is N. Set it to Y (see Variables), otherwise every file fails with "DOCTYPE is disallowed", whether the DTD is internal or external.