I am looking to use regex to block some content being typed on a form we have. Although we have ReCaptcha2 deployed, some bot somewhere is managing to use the name fields in our contact form to insert a large amount of text including a url to some supposedly pornographic link.
to prevent this I would like to restrict the text length to about 25 characters (should be enough for both first names and hyphenated surnames) and block the following: "http" and "//' I don't want urls in these fields.
Anyone more experienced that can point me in the right direction?
Block content in forms fields
I am looking to use regex to block some content being typed on a form we have. Although we have ReCaptcha2 deployed, some bot somewhere is managing to use the name fields in our contact form to insert a large amount of text including a url to some supposedly pornographic link.
to prevent this I would like to restrict the text length to about 25 characters (should be enough for both first names and hyphenated surnames) and block the following: "http" and "//' I don't want urls in these fields.
Anyone more experienced that can point me in the right direction?
thanks
David
I too would like to know how to just block URLs in the text field. Anyone?
is working on a reply...