Creating Footnotes: <fo:footnote> and <fo:footnote-body>

Footnotes are called “out-of-line” formatting objects because they add text at the bottom of the page. You create a footnote with the <fo:footnote> element, and the body text of the footnote with <fo:footnote-body>. Neither of these elements supports any properties in the current XSL-FO specification.

The following example, footnotes.fo, puts footnotes to work; in this case, I use two footnotes in the body of the document and add the text for those footnotes:

Listing 12.5. footnotes.fo
 <?xml version="1.0" encoding="UTF-8"?> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format"> <fo:layout-master-set> <fo:simple-page-master margin-right="20mm" margin-left="20mm" margin-bottom="10mm" margin-top="10mm" ...

Get Inside XSLT now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.