Assuming that you're actually interested in caching definitions on Redis
(and not just the full end to end output--if that's what you want, just
do a wrapper calss, as Keith suggested), there's just one more extra
step you have to do. Given a subclass of HTMLPurifier_DefinitionCache
(let's call it MyDefinitionCache), then you write:
$factory = HTMLPurifier_DefinitionClassFactory::instance();
$factory->register('MyCache', 'MyDefinitionCache'); // short name, class name
and now set Cache.DefinitionImpl to 'MyCache'.
Edward
Excerpts from Elliot Ali's message of 2020-04-19 07:13:25 -0700:
> I don't believe that it's that simple? Although I will probably do that too.
>
> My understanding is that htmlpurifier caches the definitions, as this
> speeds up processing times for every purification. So where, in the config,
> you normally specify "serialize" or null for the cache definition
> implementation (here
> <
http://htmlpurifier.org/live/configdoc/plain.html#Cache.DefinitionImpl>),