Moodle  2.2.1
http://www.collinsharper.com
HTMLPurifier_AttrDef_CSS Class Reference
Inheritance diagram for HTMLPurifier_AttrDef_CSS:
Collaboration diagram for HTMLPurifier_AttrDef_CSS:

Public Member Functions

 validate ($css, $config, $context)

Detailed Description

Validates the HTML attribute style, otherwise known as CSS.

Note:
We don't implement the whole CSS specification, so it might be difficult to reuse this component in the context of validating actual stylesheet declarations.
If we were really serious about validating the CSS, we would tokenize the styles and then parse the tokens. Obviously, we are not doing that. Doing that could seriously harm performance, but would make these components a lot more viable for a CSS filtering solution.

Definition at line 14 of file CSS.php.


Member Function Documentation

validate ( string,
config,
context 
)

Validates and cleans passed string according to a definition.

Parameters:
$stringString to be validated and cleaned.
$configMandatory HTMLPurifier_Config object.
$contextMandatory HTMLPurifier_AttrContext object.

Name of the current CSS property being validated.

Reimplemented from HTMLPurifier_AttrDef.

Definition at line 17 of file CSS.php.

Here is the call graph for this function:


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Enumerations