Ive got the following configuration for my filters. this is used for zend framework's setup of service manager.
$filters = [
'factories' => ['Administration\Filter\StripSpaces'=>'Zend\ServiceManager\Factory\InvokableFactory']
'aliases' => ['StripSpaces'=>'Administration\Filter\StripSpaces']
];
return ['filters'=>$filters];
For the form usage
$inputFilter->add([
'name' => 'objectclassname',
'required' => true,
'filters' => [
['name' => 'StringTrim'],
['name' => 'StripTags'],
['name' => 'StripNewlines'],
['name' => 'StripSpaces'] // here is where my StripSpaces alias is used
],
'validators' => [
[
'name' => 'StringLength',
'options' => [
'min' => 5,
'max' => 255
],
]
],
]);
And here's the error when loading the form that uses this filter:
A plugin by the name "StripSpaces" was not found in the plugin manager Zend\Filter\FilterPluginManager
As far as I know, there is no filter called StripSpaces in ZF3.