4
* Function wrapper for HTML Purifier for quick use.
5
* @note This function only includes the library when it is called. While
6
* this is efficient for instances when you only use HTML Purifier
7
* on a few of your pages, it murders bytecode caching. You still
8
* need to add HTML Purifier to your path.
9
* @note ''HTMLPurifier()'' is NOT the same as ''new HTMLPurifier()''
12
function HTMLPurifier($html, $config = null) {
13
static $purifier = false;
15
require_once 'HTMLPurifier.php';
16
$purifier = new HTMLPurifier();
18
return $purifier->purify($html, $config);