1<?
php declare(strict_types=1);
26 final public function purify(
string $html) : string
28 return $this->purifier->purify($html);
34 final public function purifyArray(array $htmlCollection) : array
36 return $this->purifier->purifyArray($htmlCollection);
82 $supportedElements = array();
84 $notSupportedTags = array(
97 foreach ($elements as $element) {
98 if (!in_array($element, $notSupportedTags)) {
99 $supportedElements[] = $element;
103 return $supportedElements;
115 if (in_array(
'u', $elements) && !in_array(
'span', $elements)) {
116 $elements[] =
'span';
An exception for terminatinating execution or to throw for unit testing.
Abstract class wrapping the HTMLPurifier instance.
purify(string $html)
@inheritDoc
removeUnsupportedElements(array $elements)
Removes all unsupported elements.
purifyArray(array $htmlCollection)
@inheritDoc
setPurifier(HTMLPurifier $purifier)
getPurifierConfigInstance()
makeElementListTinyMceCompliant(array $elements)
__construct()
ilHtmlPurifierAbstractLibWrapper constructor.
static _getCacheDirectory()
static getDataDir()
get data directory (outside webspace)
static makeDirParents($a_dir)
Create a new directory and all parent directories.
Interface for html sanitizing functionality.