2006-08-19 17:53:59 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
header('Content-type: text/html; charset=UTF-8');
|
|
|
|
|
2007-09-03 15:40:43 +00:00
|
|
|
if (!isset($_GET['standalone'])) {
|
|
|
|
require_once '../library/HTMLPurifier.auto.php';
|
|
|
|
} else {
|
|
|
|
require_once '../library/HTMLPurifier.standalone.php';
|
|
|
|
}
|
2007-01-16 21:59:29 +00:00
|
|
|
error_reporting(E_ALL | E_STRICT);
|
2006-08-19 17:53:59 +00:00
|
|
|
|
|
|
|
function escapeHTML($string) {
|
2006-08-29 19:36:40 +00:00
|
|
|
$string = HTMLPurifier_Encoder::cleanUTF8($string);
|
2006-08-19 17:53:59 +00:00
|
|
|
$string = htmlspecialchars($string, ENT_COMPAT, 'UTF-8');
|
|
|
|
return $string;
|
|
|
|
}
|
|
|
|
|