Change Numbering Styles for Ordered Lists

Ordered lists (ol) are usually numbered in XHTML output using numerals. If you want to change the numbering to alphabetical, follow these steps:

  1. Define a custom outputclass value and set it as an attribute of the ordered list, as in the following example:

    <ol outputclass="number-alpha">
        <li>A</li>
        <li>B</li>
        <li>C</li>
    </ol>

  2. Add the following code snippet in a custom CSS file:

    ol.number-alpha{
        list-style-type:lower-alpha;
    }

  3. Edit the WebHelp transformation scenario and open the Parameters tab.
    1. For a DITA transformation, set the args.css parameter to the path of your custom CSS file. Also, set the args.copycss parameter to yes to automatically copy your custom CSS in the output folder when the transformation scenario is processed.
    2. For a DocBook transformation, set the html.stylesheet parameter to the path of your custom CSS file.
  4. Run the transformation scenario.

Was this helpful?