mirror of
https://github.com/ezyang/htmlpurifier.git
synced 2025-01-23 13:51:54 +00:00
b3f0e6c86c
git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/branches/strict@1404 48356398-32a2-884e-a903-53898d9a118a
18 lines
424 B
PHP
18 lines
424 B
PHP
<?php
|
|
|
|
header('Content-type: text/html; charset=UTF-8');
|
|
|
|
if (!isset($_GET['standalone'])) {
|
|
require_once '../library/HTMLPurifier.auto.php';
|
|
} else {
|
|
require_once '../library/HTMLPurifier.standalone.php';
|
|
}
|
|
error_reporting(E_ALL | E_STRICT);
|
|
|
|
function escapeHTML($string) {
|
|
$string = HTMLPurifier_Encoder::cleanUTF8($string);
|
|
$string = htmlspecialchars($string, ENT_COMPAT, 'UTF-8');
|
|
return $string;
|
|
}
|
|
|