mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-03 09:14:48 +09:00
Update HTMLPurifier configuration and allow HTML5
This commit is contained in:
parent
1b8a41b077
commit
b89818e13d
3 changed files with 281 additions and 154 deletions
|
|
@ -815,8 +815,7 @@ function url_decode($str)
|
|||
|
||||
function purifierHtml(&$content)
|
||||
{
|
||||
$oPurifier = Purifier::getInstance();
|
||||
$oPurifier->purify($content);
|
||||
$content = Rhymix\Framework\Security\HTMLFilter::clean($content);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -830,7 +829,7 @@ function removeHackTag($content)
|
|||
$oEmbedFilter = EmbedFilter::getInstance();
|
||||
$oEmbedFilter->check($content);
|
||||
|
||||
purifierHtml($content);
|
||||
$content = Rhymix\Framework\Security\HTMLFilter::clean($content);
|
||||
|
||||
// change the specific tags to the common texts
|
||||
$content = preg_replace('@<(\/?(?:html|body|head|title|meta|base|link|script|style|applet)(/*).*?>)@i', '<$1', $content);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue