3 require_once 'HTMLPurifier/HTMLModule.php';
6 * XHTML 1.1 List Module, defines list-oriented elements. Core Module.
8 class HTMLPurifier_HTMLModule_List
extends HTMLPurifier_HTMLModule
13 // According to the abstract schema, the List content set is a fully formed
14 // one or more expr, but it invariably occurs in an optional declaration
15 // so we're not going to do that subtlety. It might cause trouble
16 // if a user defines "List" and expects that multiple lists are
17 // allowed to be specified, but then again, that's not very intuitive.
18 // Furthermore, the actual XML Schema may disagree. Regardless,
19 // we don't have support for such nested expressions without using
20 // the incredibly inefficient and draconic Custom ChildDef.
22 var $content_sets = array('Flow' => 'List');
24 function HTMLPurifier_HTMLModule_List() {
25 $this->addElement('ol', true, 'List', 'Required: li', 'Common');
26 $this->addElement('ul', true, 'List', 'Required: li', 'Common');
27 $this->addElement('dl', true, 'List', 'Required: dt | dd', 'Common');
29 $this->addElement('li', true, false, 'Flow', 'Common');
31 $this->addElement('dd', true, false, 'Flow', 'Common');
32 $this->addElement('dt', true, false, 'Inline', 'Common');