Class HTMLPurifier_Injector_RemoveEmpty
Injects tokens into the document while parsing for well-formedness. This
enables "formatter-like" functionality such as auto-paragraphing,
smiley-ification and linkification to take place.
A note on how handlers create changes; this is done by assigning a new value
to the $token reference. These values can take a variety of forms and are best
described HTMLPurifier_Strategy_MakeWellFormed->processToken()
documentation.
-
HTMLPurifier_Injector
-
HTMLPurifier_Injector_RemoveEmpty
Methods summary
public
Boolean
|
#
prepare( $config $config, $context $context )
Prepares the injector by giving it the config and context objects: this
allows references to important variables to be made within the injector. This
function also checks if the HTML environment will work with the Injector (see
checkNeeded()).
Prepares the injector by giving it the config and context objects: this
allows references to important variables to be made within the injector. This
function also checks if the HTML environment will work with the Injector (see
checkNeeded()).
Parameters
- $config
$config Instance of HTMLPurifier_Config
- $context
$context Instance of HTMLPurifier_Context
Returns
Boolean false if success, string of missing needed element/attribute if failure
Overrides
|
public
|
#
handleElement( & $token )
Handler that is called when a start or empty token is processed
Handler that is called when a start or empty token is processed
Overrides
|