2007-04-30 21:19:15 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Special-case enum attribute definition that lazy loads allowed frame targets
|
|
|
|
*/
|
|
|
|
class HTMLPurifier_AttrDef_HTML_FrameTarget extends HTMLPurifier_AttrDef_Enum
|
|
|
|
{
|
|
|
|
|
2007-11-25 02:24:39 +00:00
|
|
|
public $valid_values = false; // uninitialized value
|
|
|
|
protected $case_sensitive = false;
|
2007-04-30 21:19:15 +00:00
|
|
|
|
2007-11-29 04:29:51 +00:00
|
|
|
public function __construct() {}
|
2007-04-30 21:19:15 +00:00
|
|
|
|
2008-01-05 00:10:43 +00:00
|
|
|
public function validate($string, $config, $context) {
|
2007-04-30 21:19:15 +00:00
|
|
|
if ($this->valid_values === false) $this->valid_values = $config->get('Attr', 'AllowedFrameTargets');
|
|
|
|
return parent::validate($string, $config, $context);
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|