3 require_once 'HTMLPurifier/AttrDef.php';
6 * Validates a boolean attribute
8 class HTMLPurifier_AttrDef_HTML_Bool
extends HTMLPurifier_AttrDef
12 var $minimized = true;
14 function HTMLPurifier_AttrDef_HTML_Bool($name = false) {$this->name
= $name;}
16 function validate($string, $config, &$context) {
17 if (empty($string)) return false;
22 * @param $string Name of attribute
24 function make($string) {
25 return new HTMLPurifier_AttrDef_HTML_Bool($string);