|
| __construct ($config=null) |
| Initializes the purifier.
|
|
| addFilter ($filter) |
| Adds a filter to process the output.
|
|
| purify ($html, $config=null) |
| Filters an HTML snippet/document to be XSS-free and standards-compliant.
|
|
| purifyArray ($array_of_html, $config=null) |
| Filters an array of HTML snippets.
|
|
|
static | getInstance ($prototype=null) |
| Singleton for enforcing just one HTML Purifier in your system.
|
|
static | instance ($prototype=null) |
| Singleton for enforcing just one HTML Purifier in your system.
|
|
|
| $config |
| Global configuration object.
|
|
| $context |
| Resultant context of last run purification.
|
|
| $version = '4.15.0' |
| Version of HTML Purifier.
|
|
const | VERSION = '4.15.0' |
| Constant with version of HTML Purifier.
|
|
◆ __construct()
HTMLPurifier::__construct |
( |
| $config = null | ) |
|
Initializes the purifier.
- Parameters
-
◆ addFilter()
HTMLPurifier::addFilter |
( |
| $filter | ) |
|
Adds a filter to process the output.
First come first serve
- Parameters
-
◆ getInstance()
static HTMLPurifier::getInstance |
( |
| $prototype = null | ) |
|
|
static |
Singleton for enforcing just one HTML Purifier in your system.
- Parameters
-
- Return values
-
- Note
- Backwards compatibility, see instance()
◆ instance()
static HTMLPurifier::instance |
( |
| $prototype = null | ) |
|
|
static |
Singleton for enforcing just one HTML Purifier in your system.
- Parameters
-
- Return values
-
◆ purify()
HTMLPurifier::purify |
( |
| $html, |
|
|
| $config = null ) |
Filters an HTML snippet/document to be XSS-free and standards-compliant.
- Parameters
-
string | $html | String of HTML to purify |
HTMLPurifier_Config | $config | Config object for this operation, if omitted, defaults to the config object specified during this object's construction. The parameter can also be any type that HTMLPurifier_Config\create() supports. |
- Return values
-
◆ purifyArray()
HTMLPurifier::purifyArray |
( |
| $array_of_html, |
|
|
| $config = null ) |
Filters an array of HTML snippets.
- Parameters
-
- Return values
-
string[] | Array of purified HTML |
◆ $config
◆ $context
◆ $version
HTMLPurifier::$version = '4.15.0' |
Version of HTML Purifier.
@type string
The documentation for this class was generated from the following file:
- lib/htmlpurifier/HTMLPurifier.php