##### 24.4.6.6 Providing outputclass attributes for all elements

By default, DITA2Go does not try to assign CSS classes to DITA elements (unless you set [CSS]UseCSS=Yes; see §31.4 Specifying CSS file and link options).

To direct DITA2Go to provide an outputclass attribute for elements that allow this attribute:

    [DITAOptions]
    ; UseOutputClass = No (default when [CSS]UseCSS=No)
    ;  or Yes (default when [CSS]UseCSS=Yes)
    UseOutputClass = Yes

When UseOutputClass=Yes, DITA2Go includes an outputclass attribute where allowed. The value of the attribute is the [ParaClasses] or [CharClasses] assignment (if any) for the format mapped to the element, otherwise the name of the format mapped to the element. See §31.7 Assigning CSS classes.

Note: To include outputclass attributes, make sure your configuration file does not specify [CSS]WriteClassAttributes=No.

Root element outputclass

The only way to include an outputclass attribute in the root element is with a DITATopicOutputclass marker: place the marker anywhere in the topic, and make the content of the marker the value of the outputclass attribute.

Previous Topic: 24.4.6.5 Specifying attribute values for an inline element

Next Topic: 24.4.7 Preserving whitespace in block elements

Parent Topic: 24.4.6 Assigning attributes to DITA elements

Sibling Topics:

24.4.6.1 Specifying a value for the id attribute

24.4.6.2 Including an id attribute in every element

24.4.6.3 Specifying attribute values for the root element of a topic

24.4.6.4 Specifying attribute values for a block element or parent

24.4.6.5 Specifying attribute values for an inline element

Table of Contents • Index