3 require_once 'HTMLPurifier/HTMLModule.php';
5 require_once 'HTMLPurifier/AttrDef/URI.php';
6 require_once 'HTMLPurifier/AttrTransform/ImgRequired.php';
9 * XHTML 1.1 Image Module provides basic image embedding.
10 * @note There is specialized code for removing empty images in
11 * HTMLPurifier_Strategy_RemoveForeignElements
13 class HTMLPurifier_HTMLModule_Image
extends HTMLPurifier_HTMLModule
17 var $elements = array('img');
18 var $content_sets = array('Inline' => 'img');
20 function HTMLPurifier_HTMLModule_Image() {
22 'img', true, 'Inline', 'Empty', 'Common',
27 'src' => new HTMLPurifier_AttrDef_URI(true), // embedded
31 $this->info
['img']->attr_transform_post
[] =
32 new HTMLPurifier_AttrTransform_ImgRequired();