Hey,
I am looking to make a regular expression that will exclude a certain string from being allowed on our registration page.
The field is a simple text field.
I am using the option IsRegexMatch.
I found out that the field can accept perl regular expressions. I found this:
\w+\b(?<!\bfox)
Which is a negative lookbehind.
I modified it to match our requirements
\w+\b(?<!\b[fF][oO][xX])
However it only works if the word "fox" is put in by itself.
If you add any other word it is accepted.
This will fail
fox
Fox
FOX
etc...
This will be excepted
Fox company
fox company
company fox
company Fox
etc...
Is there an easier way to doing this?
Or perhaps I having gone completely wrong with my regular expression.
I had tested my regular expression here and it seemed to work okay.
Thank you,
Cheers