How do you change the values of conditional attributes in DITA for different output scenarios?

Organizations can modify conditional attribute values in DITA for diverse output scenarios using DITAVAL files. These files allow the control of which conditions are active or inactive, enabling content customization for specific outputs.

Adapting Conditional Attributes in DITA for Various Output Scenarios

To adapt conditional attributes in DITA for various output scenarios, organizations follow steps including creating DITAVAL files, associating DITAVAL files, defining conditions, setting activate/deactivate conditions, and generating output.

Create DITAVAL Files

Develop DITAVAL files, XML documents, to specify conditions and their values for different output situations.

Associate DITAVAL Files

Link DITAVAL files to the DITA transformation process, typically through publishing tools. By designating a DITAVAL file during processing, the tool applies specified conditions for that output.

Define Conditions

Inside the DITAVAL file, articulate the conditions and set their values, usually as attribute-value pairs, such as “platform=windows” or “audience=beginner.”

Activate/Deactivate Conditions

In the DITAVAL file, indicate which conditions should be active (enabled) and which should be inactive (disabled) for a specific output scenario. For example, an author might activate “platform=windows” for a Windows-specific output while deactivating it for other cases.

Generate Output

When generating output, the publishing tool employs the associated DITAVAL file to determine active or inactive conditions. It then applies these conditions to filter or tailor the content accordingly.


In a software documentation project, an organization creates a DITAVAL file for different versions of a user manual. For the “Advanced Users” version, the DITAVAL file activates the “audience=advanced” condition and deactivates the “audience=beginner” condition. When generating the user manual for advanced users, the publishing tool uses this DITAVAL file to customize the content, displaying information tailored to advanced users while excluding beginner-level content. This ensures that the content aligns precisely with the needs of the target audience for each output scenario.