angularjs - display errors when the username doesn't fit pattern -


i'm using symfony , want display errors when username doesn't fit pattern, how can that?

{{ form_widget(form.username, {'attr':{'pattern': '[a-za-z]*'} }) }} 

try add assert property in entity class.

check out asserts : http://symfony.com/doc/current/validation.html

and 1 regex : http://symfony.com/doc/current/reference/constraints/regex.html


Comments

Popular posts from this blog

php - Permission denied. Laravel linux server -

google bigquery - Delta between query execution time and Java query call to finish -

python - Pandas two dataframes multiplication? -