Strehler::FormFu::Validator::FilenameTooLong - FormFu Validator for File field in image form.
A FormFu Validator to ensure that a user can't load an image with a name longer than 50 characters using the Image entity.
Images are not renamed when loaded in Strehler and their names are saved in the database. Database field for image name can't afford names longer than 50 characters.
This validator could be loaded using FormFu namespace, but for now I'll keep it in the Strehler distribution.
In image form configuration:
elements: - type: File name: photo label: Image attributes: class: span5 validators: - type: '+Strehler::FormFu::Validator::FilenameTooLong' message: 'Filename is too long'
To install Strehler, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Strehler
CPAN shell
perl -MCPAN -e shell install Strehler
For more information on module installation, please visit the detailed CPAN module installation guide.