When trying to add a custom plugin as a PHP class, such as:
<?php
class Dwoo_Filter_fix_address_class extends Dwoo_Filter
{
public function process($str)
{
return str_replace(
array('@', '.', '-'),
array(' at ', ' dot ', ' dash '),
$str
);
}
}
$dwoo->addPlugin('email_safe_class', 'fix_address_class');
Get the next error code:
Fatal error: Uncaught exception 'Dwoo_Exception' with message 'Callback could not be processed correctly, please check that the function/class you used exists'
Dwoo_Exception: Callback could not be processed correctly, please check that the function/class you used exists in /var/www/lib/Dwoo/Core.php on line 497
Not an error! Just an error, in this case, we need to use the full name of the class, such as:
$dwoo->addPlugin('email_safe_class', 'Dwoo_Filter_fix_address_class');
When trying to add a custom plugin as a PHP class, such as:
Get the next error code: