HTMLPurifier 4.4.0
/home/ezyang/Dev/htmlpurifier/library/HTMLPurifier/AttrDef/CSS/Composite.php
Go to the documentation of this file.
00001 <?php
00002 
00012 class HTMLPurifier_AttrDef_CSS_Composite extends HTMLPurifier_AttrDef
00013 {
00014 
00019     public $defs;
00020 
00024     public function __construct($defs) {
00025         $this->defs = $defs;
00026     }
00027 
00028     public function validate($string, $config, $context) {
00029         foreach ($this->defs as $i => $def) {
00030             $result = $this->defs[$i]->validate($string, $config, $context);
00031             if ($result !== false) return $result;
00032         }
00033         return false;
00034     }
00035 
00036 }
00037 
00038 // vim: et sw=4 sts=4