-
Notifications
You must be signed in to change notification settings - Fork 55
Open
Labels
Milestone
Description
Using this constraint with JsFormValidator v1.2.1 :
/**
* @Assert\Regex(
* pattern="/\d/",
* match=false,
* message="Your name cannot contain a number"
* )
*/
The javascript error message will appear when the name does NOT contain a number.
Of course there is a workaround :
/**
* @Assert\Regex(
* pattern="/^[^\d]*$/",
* message="Your name cannot contain a number"
* )
*/
But it would be great if JsFormValidator could support "match=false".