What is the best way to add an email validation in Sonata Admin?
I saw a discussion in Google groups about it and it says:
"Why force developers to repeat all validation constraints twice?"
https://groups.google.com/forum/?fromgroups=#!topic/sonata-users/xO64f_haMks
Is that true? Or is there a way to use the Symfony2 Validation at the same time?
Finally it works like this:
public function configureFormFields(FormMapper $formMapper)
{
$formMapper
->add('email', 'email')
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.