ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
HTMLPurifier.func.php File Reference

Defines a function wrapper for HTML Purifier for quick use. More...

Go to the source code of this file.

Functions

 HTMLPurifier ($html, $config=null)
 Purify HTML. More...
 

Detailed Description

Defines a function wrapper for HTML Purifier for quick use.

Note
''HTMLPurifier()'' is NOT the same as ''new HTMLPurifier()''

Definition in file HTMLPurifier.func.php.

Function Documentation

◆ HTMLPurifier()

HTMLPurifier (   $html,
  $config = null 
)

Purify HTML.

Parameters
string$htmlString HTML to purify
mixed$configConfiguration to use, can be any value accepted by HTMLPurifier_Config::create()
Returns
string

Definition at line 16 of file HTMLPurifier.func.php.

17{
18 static $purifier = false;
19 if (!$purifier) {
20 $purifier = new HTMLPurifier();
21 }
22 return $purifier->purify($html, $config);
23}
HTMLPurifier($html, $config=null)
Purify HTML.
$html
Definition: example_001.php:87

References $html, and HTMLPurifier().

Referenced by ilHtmlPurifierAbstractLibWrapper\__construct(), HTMLPurifier(), HTMLPurifier\instance(), and kses().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: