php HTML净化器

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了php HTML净化器相关的知识,希望对你有一定的参考价值。

<?php 

  require_once '/path/to/HTMLPurifier.auto.php';

  $config = HTMLPurifier_Config::createDefault();
  $purifier = new HTMLPurifier($config);
  $clean_html = $purifier->purify($dirty_html);

?>

以上是关于php HTML净化器的主要内容,如果未能解决你的问题,请参考以下文章

简单PHP随机化器

Laravel 4 - HTML 净化器

小米空气净化器体验

除甲醛空气净化器哪个牌子最好

Angular 2:我如何将指令应用于净化的 html/innerhtml

戴森:将于2022年内发布“空气净化耳机”