following the rule of thumb never to trust data received from end users before putting it to good use, i tried one of the core validators\' match. before placing it as pattern,
I guess what is really happening here is only client validation fails.
This is because PHP regex engine is different from the JS one.
If you are using regex101 service to check the expression you can test it by switching the flavor on the left side menu from pcre (php)
to javascript
. If pcre
is ok then it works on the server side, if javascript
is ok it also works on the client side.
The solutions here are: