mirror of
https://github.com/ezyang/htmlpurifier.git
synced 2025-07-30 19:00:10 +02:00
Setup include web. Unit tests should now be able to be run independently.
git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@75 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
@@ -1,5 +1,9 @@
|
||||
<?php
|
||||
|
||||
require_once 'HTMLPurifier/Lexer.php';
|
||||
require_once 'HTMLPurifier/Definition.php';
|
||||
require_once 'HTMLPurifier/Generator.php';
|
||||
|
||||
class HTMLPurifier
|
||||
{
|
||||
|
||||
@@ -14,11 +18,9 @@ class HTMLPurifier
|
||||
}
|
||||
|
||||
function purify($html) {
|
||||
|
||||
$tokens = $this->lexer->tokenizeHTML($html);
|
||||
$tokens = $this->definition->purifyTokens($tokens);
|
||||
return $this->generator->generateFromTokens($tokens);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user