HTMLPurifier 4.4.0
HTMLPurifier_Injector_RemoveSpansWithoutAttributes Class Reference

Injector that removes spans with no attributes. More...

Inheritance diagram for HTMLPurifier_Injector_RemoveSpansWithoutAttributes:
HTMLPurifier_Injector HTMLPurifier_Injector

List of all members.

Public Member Functions

 prepare ($config, $context)
 Prepares the injector by giving it the config and context objects: this allows references to important variables to be made within the injector.
 handleElement (&$token)
 Handler that is called when a start or empty token is processed.
 handleEnd (&$token)
 Handler that is called when an end token is processed.
 prepare ($config, $context)
 Prepares the injector by giving it the config and context objects: this allows references to important variables to be made within the injector.
 handleElement (&$token)
 Handler that is called when a start or empty token is processed.
 handleEnd (&$token)
 Handler that is called when an end token is processed.

Public Attributes

 $name = 'RemoveSpansWithoutAttributes'
 Advisory name of injector, this is for friendly error messages.
 $needed = array('span')
 Array of elements and attributes this injector creates and therefore need to be allowed by the definition.

Private Attributes

 $attrValidator
 $config
 Used by AttrValidator.
 $context

Detailed Description

Injector that removes spans with no attributes.

Definition at line 6 of file RemoveSpansWithoutAttributes.php.


Member Function Documentation

HTMLPurifier_Injector_RemoveSpansWithoutAttributes::handleElement ( &$  token)

Handler that is called when a start or empty token is processed.

Reimplemented from HTMLPurifier_Injector.

Definition at line 26 of file RemoveSpansWithoutAttributes.php.

References HTMLPurifier_Injector::forwardUntilEndToken().

HTMLPurifier_Injector_RemoveSpansWithoutAttributes::handleElement ( &$  token)

Handler that is called when a start or empty token is processed.

Reimplemented from HTMLPurifier_Injector.

Definition at line 14553 of file HTMLPurifier.standalone.php.

References HTMLPurifier_Injector::forwardUntilEndToken().

HTMLPurifier_Injector_RemoveSpansWithoutAttributes::handleEnd ( &$  token)

Handler that is called when an end token is processed.

Reimplemented from HTMLPurifier_Injector.

Definition at line 14580 of file HTMLPurifier.standalone.php.

HTMLPurifier_Injector_RemoveSpansWithoutAttributes::handleEnd ( &$  token)

Handler that is called when an end token is processed.

Reimplemented from HTMLPurifier_Injector.

Definition at line 53 of file RemoveSpansWithoutAttributes.php.

HTMLPurifier_Injector_RemoveSpansWithoutAttributes::prepare ( config,
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()).

Parameters:
$configInstance of HTMLPurifier_Config
$contextInstance of HTMLPurifier_Context
Returns:
Boolean false if success, string of missing needed element/attribute if failure

Reimplemented from HTMLPurifier_Injector.

Definition at line 14546 of file HTMLPurifier.standalone.php.

References $config, $context, and prepare().

HTMLPurifier_Injector_RemoveSpansWithoutAttributes::prepare ( config,
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()).

Parameters:
$configInstance of HTMLPurifier_Config
$contextInstance of HTMLPurifier_Context
Returns:
Boolean false if success, string of missing needed element/attribute if failure

Reimplemented from HTMLPurifier_Injector.

Definition at line 19 of file RemoveSpansWithoutAttributes.php.

References $config, and $context.

Referenced by prepare().


Member Data Documentation

HTMLPurifier_Injector_RemoveSpansWithoutAttributes::$attrValidator [private]

Definition at line 11 of file RemoveSpansWithoutAttributes.php.

HTMLPurifier_Injector_RemoveSpansWithoutAttributes::$config [private]

Used by AttrValidator.

Definition at line 16 of file RemoveSpansWithoutAttributes.php.

Referenced by prepare().

HTMLPurifier_Injector_RemoveSpansWithoutAttributes::$context [private]

Definition at line 17 of file RemoveSpansWithoutAttributes.php.

Referenced by prepare().

HTMLPurifier_Injector_RemoveSpansWithoutAttributes::$name = 'RemoveSpansWithoutAttributes'

Advisory name of injector, this is for friendly error messages.

Reimplemented from HTMLPurifier_Injector.

Definition at line 8 of file RemoveSpansWithoutAttributes.php.

HTMLPurifier_Injector_RemoveSpansWithoutAttributes::$needed = array('span')

Array of elements and attributes this injector creates and therefore need to be allowed by the definition.

Takes form of array('element' => array('attr', 'attr2'), 'element2')

Reimplemented from HTMLPurifier_Injector.

Definition at line 9 of file RemoveSpansWithoutAttributes.php.


The documentation for this class was generated from the following files: