Hi,
I'm trying to use MathSpamProtection in a custom form which happens to be very long.
When the server side form validation fails (e.g. required field not filled, invalid value or spam protection fails) the error message is attached to the field. Since the form is very large and the MathSpamProtectionField is at the bottom, if the spam protection validation fails, they may not notice the error message and assume that the submission was successful. So I'd like to set the global error message (which is at the top of the form in this case) to alert them that something is amiss.
A couple of questions:
- 1) How (& where) can I also set a global error message upon the spam protection validation failure?
- 2) Do I have the extend Form to achieve this or I can I do it in the page controller in which the submission handler is present?
Thank you.
VWD.