Class HTMLPurifier_AttrTransform_EnumToCSS
Generic pre-transform that converts an attribute with a fixed number of
values (enumerated) to CSS.
-
HTMLPurifier_AttrTransform
-
HTMLPurifier_AttrTransform_EnumToCSS
Methods summary
public
|
#
__construct( $attr $attr, $enumToCSS $enum_to_css, $case_sensitive $case_sensitive = false )
Parameters
- $attr
$attr String attribute name to transform from
- $enum_to_css
$enumToCSS Lookup array of attribute values to CSS
- $case_sensitive
$case_sensitive Boolean case sensitivity indicator, default false
|
public
|
#
transform( $attr $attr, $config $config, $context $context )
Abstract: makes changes to the attributes dependent on multiple values.
Abstract: makes changes to the attributes dependent on multiple values.
Parameters
- $attr
$attr Assoc array of attributes, usually from HTMLPurifier_Token_Tag::$attr
- $config
$config Mandatory HTMLPurifier_Config object.
- $context
$context Mandatory HTMLPurifier_Context object
Returns
Processed attribute array.
|
Properties summary
protected
|
$attr
|
|
#
Name of attribute to transform from
Name of attribute to transform from
|
protected
array
|
$enumToCSS
|
array() |
#
Lookup array of attribute values to CSS
Lookup array of attribute values to CSS
|
protected
boolean
|
$caseSensitive
|
false |
#
Case sensitivity of the matching
Case sensitivity of the matching
Warning
Currently can only be guaranteed to work with ASCII values.
|