HTMLPurifier_IDAccumulator
in package
Component of HTMLPurifier_AttrContext that accumulates IDs to prevent dupes
Tags
Table of Contents
Properties
- $ids : mixed
- Lookup table of IDs we've accumulated.
Methods
- add() : bool
- Add an ID to the lookup table.
- build() : HTMLPurifier_IDAccumulator
- Builds an IDAccumulator, also initializing the default blacklist
- load() : mixed
- Load a list of IDs into the lookup table
Properties
$ids
Lookup table of IDs we've accumulated.
public
mixed
$ids
= array()
Tags
Methods
add()
Add an ID to the lookup table.
public
add(string $id) : bool
Parameters
- $id : string
-
ID to be added.
Return values
bool —status, true if success, false if there's a dupe
build()
Builds an IDAccumulator, also initializing the default blacklist
public
static build(HTMLPurifier_Config $config, HTMLPurifier_Context $context) : HTMLPurifier_IDAccumulator
Parameters
- $config : HTMLPurifier_Config
-
Instance of HTMLPurifier_Config
- $context : HTMLPurifier_Context
-
Instance of HTMLPurifier_Context
Return values
HTMLPurifier_IDAccumulator —Fully initialized HTMLPurifier_IDAccumulator
load()
Load a list of IDs into the lookup table
public
load(mixed $array_of_ids) : mixed
Parameters
- $array_of_ids : mixed
-
Array of IDs to load