3 require_once 'HTMLPurifier/Printer.php';
5 class HTMLPurifier_Printer_CSSDefinition
extends HTMLPurifier_Printer
10 function render($config) {
11 $this->def
= $config->getCSSDefinition();
14 $ret .= $this->start('div', array('class' => 'HTMLPurifier_Printer'));
15 $ret .= $this->start('table');
17 $ret .= $this->element('caption', 'Properties ($info)');
19 $ret .= $this->start('thead');
20 $ret .= $this->start('tr');
21 $ret .= $this->element('th', 'Property', array('class' => 'heavy'));
22 $ret .= $this->element('th', 'Definition', array('class' => 'heavy', 'style' => 'width:auto;'));
23 $ret .= $this->end('tr');
24 $ret .= $this->end('thead');
26 ksort($this->def
->info
);
27 foreach ($this->def
->info
as $property => $obj) {
28 $name = $this->getClass($obj, 'AttrDef_');
29 $ret .= $this->row($property, $name);
32 $ret .= $this->end('table');
33 $ret .= $this->end('div');