Form Validation (not_regex) #6114
-
Any Form validation wizards out there? I want to exclude email addresses with certain domains being able to submit a form. My idea was to use the 'not_regex' to validate the form to achieve this. Based on the idea of excluding 'gmail.com' addresses, I have the following in place on the blueprint:
I've also tried:
When I attempt to submit the form with this 'not_regex' rule in place though I'm seeing a '500 Internal Server Error'. It's probably me... not a bug, but can't work out what I'm doing wrong based on the docs! Can anyone see what I'm doing wrong, or know a better way to do this? When I attemp to submit, I'm seeing the following in my log:
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Ok, first, not sure that Second, I think this is a bug, look like it should be supported but is causing an error, can you open an issue for it? |
Beta Was this translation helpful? Give feedback.
-
Regex validators are quirky in Laravel as well. Quite a few times I had to use an array instead of the pipe syntax. Maybe create a custom validation rule and add that. |
Beta Was this translation helpful? Give feedback.
Regex validators are quirky in Laravel as well. Quite a few times I had to use an array instead of the pipe syntax.
Maybe create a custom validation rule and add that.