API - XOOPS 2.5.11 Beta 2
By monxoops.fr
HTMLPurifier_ChildDef_Chameleon Class Reference
Inheritance diagram for HTMLPurifier_ChildDef_Chameleon:
Collaboration diagram for HTMLPurifier_ChildDef_Chameleon:

Public Member Functions

 __construct ($inline, $block)
 
 validateChildren ($children, $config, $context)
 
- Public Member Functions inherited from HTMLPurifier_ChildDef
 getAllowedElements ($config)
 
 validateChildren ($children, $config, $context)
 

Data Fields

 $inline
 
 $block
 
 $type = 'chameleon'
 
- Data Fields inherited from HTMLPurifier_ChildDef
 $type
 
 $allow_empty
 
 $elements = array()
 

Detailed Description

Definition that uses different definitions depending on context.

The del and ins tags are notable because they allow different types of elements depending on whether or not they're in a block or inline context. Chameleon allows this behavior to happen by using two different definitions depending on context. While this somewhat generalized, it is specifically intended for those two tags.

Constructor & Destructor Documentation

◆ __construct()

__construct (   $inline,
  $block 
)
Parameters
array$inlineList of elements to allow when inline.
array$blockList of elements to allow when block.

Member Function Documentation

◆ validateChildren()

validateChildren (   $children,
  $config,
  $context 
)
Parameters
HTMLPurifier_Node[]$children
HTMLPurifier_Config$config
HTMLPurifier_Context$context
Returns
bool

Reimplemented from HTMLPurifier_ChildDef.

Field Documentation

◆ $block

$block

Instance of the definition object to use when block. @type HTMLPurifier_ChildDef_Optional

◆ $inline

$inline

Instance of the definition object to use when inline. Usually stricter. @type HTMLPurifier_ChildDef_Optional

◆ $type

$type = 'chameleon'

@type string


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