HtmlPurifier

Type
Class
Namespace
craft\helpers
Inherits
craft\helpers\HtmlPurifier » yii\helpers\HtmlPurifier (opens new window) » yii\helpers\BaseHtmlPurifier (opens new window)
Since
3.0.0

HtmlPurifier provides an ability to clean up HTML from any harmful code.

View source (opens new window)

# Public Methods

Method Description
cleanUtf8()
configure() Allow the extended HtmlPurifier class to set some default config options.
convertToUtf8()
process() (opens new window) Passes markup through HTMLPurifier making it safe to output to end user.

# cleanUtf8()

View source (opens new window)

Arguments

Returns

string (opens new window)

# configure()

Allow the extended HtmlPurifier class to set some default config options.

View source (opens new window)

Arguments

  • $config (\HTMLPurifier_Config)

# convertToUtf8()

View source (opens new window)

Arguments

Returns

string (opens new window)