mirror of
https://github.com/ezyang/htmlpurifier.git
synced 2024-11-09 23:28:42 +00:00
HTMLPurifier.php - Minor styling and documentation updates.
git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@342 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
parent
0ac97774d4
commit
90279eaee2
@ -34,6 +34,9 @@ require_once 'HTMLPurifier/Strategy/Core.php';
|
|||||||
* Facade that performs calls to the HTMLPurifier_Lexer,
|
* Facade that performs calls to the HTMLPurifier_Lexer,
|
||||||
* HTMLPurifier_Strategy and HTMLPurifier_Generator subsystems in order to
|
* HTMLPurifier_Strategy and HTMLPurifier_Generator subsystems in order to
|
||||||
* purify HTML.
|
* purify HTML.
|
||||||
|
*
|
||||||
|
* @todo We need an easier way to inject strategies, it'll probably end
|
||||||
|
* up getting done through config though.
|
||||||
*/
|
*/
|
||||||
class HTMLPurifier
|
class HTMLPurifier
|
||||||
{
|
{
|
||||||
@ -46,14 +49,16 @@ class HTMLPurifier
|
|||||||
* Initializes the purifier.
|
* Initializes the purifier.
|
||||||
* @param $config Optional HTMLPurifier_Config object for all instances of
|
* @param $config Optional HTMLPurifier_Config object for all instances of
|
||||||
* the purifier, if omitted, a default configuration is
|
* the purifier, if omitted, a default configuration is
|
||||||
* supplied.
|
* supplied (which can be overridden on a per-use basis).
|
||||||
*/
|
*/
|
||||||
function HTMLPurifier($config = null) {
|
function HTMLPurifier($config = null) {
|
||||||
|
|
||||||
$this->config = $config ? $config : HTMLPurifier_Config::createDefault();
|
$this->config = $config ? $config : HTMLPurifier_Config::createDefault();
|
||||||
|
|
||||||
$this->lexer = HTMLPurifier_Lexer::create();
|
$this->lexer = HTMLPurifier_Lexer::create();
|
||||||
$this->strategy = new HTMLPurifier_Strategy_Core();
|
$this->strategy = new HTMLPurifier_Strategy_Core();
|
||||||
$this->generator = new HTMLPurifier_Generator();
|
$this->generator = new HTMLPurifier_Generator();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user