src/Core/Helper.php
static function stripSelectedTags($str, $disallowable = '<script><iframe><style><link>')
    {
        $disallowable = trim(str_replace(array('>', '<'), array('', '|'), $disallowable), '|');
        $str = str_replace(array('&lt;', '&gt;'), array('<', '>'), $str);
        $str = preg_replace("~<({$disallowable})[^>]*>(.*?<\s*\/(\\1)[^>]*>)?~is", '$2', $str);

        return $str;
    }
static function stripSelectedTags($str, $disallowable = '<script><iframe><style><link>')
    {
        $disallowable = trim(str_replace(array('>', '<'), array('', '|'), $disallowable), '|');
        $str = str_replace(array('&lt;', '&gt;'), array('<', '>'), $str);
        $str = preg_replace("~<({$disallowable})[^>]*>(.*?<\s*\/(\\1)[^>]*>)?~is", '$2', $str);

        return $str;
    }
过滤非法标签

@param string $str
@param string $disallowable
@return mixed