This recipe allows users to number the sections on the page.
It is a slight modification of the NumberedHeaders recipe, to allow for better control as to which header level gets numbered.
To start section numbering, include the directive (:numbered-sections:). To stop section numbering, include (:nonumbered-sections:). The (:numbered-sections:) directive takes an optional format parameter
where format_string is of the following form:
where a, b, c, d, e, f can be the digits 0 or 1 or the characters a or A. If a digit is set to 0 at level L, then level L section headers don't get counted. If a digit is set to 1, a or A at level L, then level L section headers get counted starting respectively with 1, a or A.
The inner separator can be controlled as well: 1X1Y1Z1U1V1 will result in X, Y, Z, ... being separator characters between numbers.
The default value for $DDNumFmt is 18.104.22.168.1.1.
For example, assume your sectioning is
Then format 22.214.171.124.1.a yields the following section numbering:
Format 0.0.0.0.1-a yields the following section numbering:
You may also define $DDNumFmt="a.b.c.d.e.f"; in your config.php, to specify a site-specific default.
The NumberedSections recipe can be combined with the 'numtoc', 'sectionedit' and other section-related recipes.
Version 1.1 - Fixed handling of GroupHeader and GroupFooter
If the recipe has multiple releases, then release notes can be placed here. Note that it's often easier for people to work with "release dates" instead of "version numbers".