1 Definition Lists 2 ---------------- 3 4 Summary 5 ------- 6 7 The Definition List Extension adds the ability to create definition list in 8 Markdown documents. 9 10 This extension is included in the standard Markdown library. 11 12 Syntax 13 ------ 14 15 Definition lists are defined using the syntax established in 16 [PHP Markdown Extra][php]. 17 18 [php]: http://www.michelf.com/projects/php-markdown/extra/#def-list 19 20 Thus, the following text (taken from the above referenced PHP documentation): 21 22 Apple 23 : Pomaceous fruit of plants of the genus Malus in 24 the family Rosaceae. 25 26 Orange 27 : The fruit of an evergreen tree of the genus Citrus. 28 29 will be rendered like so: 30 31 <dl> 32 <dt>Apple</dt> 33 <dd>Pomaceous fruit of plants of the genus Malus in 34 the family Rosaceae.</dd> 35 36 <dt>Orange</dt> 37 <dd>The fruit of an evergreen tree of the genus Citrus.</dd> 38 </dl> 39 40 41 Usage 42 ----- 43 44 From the Python interpreter: 45 46 >>> html = markdown.markdown(text, ['def_list']) 47 48 To use with other extensions, just add them to the list, like this: 49 50 >>> html = markdown.markdown(text, ['def_list', 'footnotes']) 51 52 The extension can also be called from the command line using Markdown's `-x` 53 parameter: 54 55 markdown.py -x def_list source.txt > output.html 56