Forums

Form validation fails but still redirects

rkotwal 25 Feb, 2013
I'm using V4 - latest version with J2.5.

Due to a spammer who's sending me blank entries every 5 minutes from the same IP - I realised the forms validation isn't working as expected.

If you go to http://revealedresources.com/marketing-services and hit submit on a blank form, it will redirect to a thank you page - with a message up the top: You must provide at least one recipient email address.

I then get the requisite email template - with blank fields.

If I turn off the redirect, I get the error message on the original page. Still get the email!

On the form wizard, I have "show html" on load.

On Submit:

Custom code (blank)
Email - Form Submitted (with some parameters)
Email - Recipient
Redirect User.

Am I missing something?

Thanks,

Rashid.
GreyHead 25 Feb, 2013
Hi Rashid,

Please see this FAQ

The error message comes from the second Email action - but by then the first one has been sent.

Bob
rkotwal 25 Feb, 2013
Thanks Bob. I'll try the HoneyPot check.

BTW, how does one stop the form redirecting (inappropriately) if it hasn't been filled out correctly by a human?

Rashid.
GreyHead 25 Feb, 2013
Hi Rashid,

I'm not sure what you mean by 'redirecting inappropriately'? If I think it is a spammer I usually redirect to the FBI anti-spam site.

Bob
rkotwal 26 Feb, 2013
Hi Bob,

I have 3 required fields on the form.

First Name
Last Name
Email

Say they fill in nothing and hit submit - the page the form is on redirects to the designated thank you page where the error message (you need to put in a valid email address) shows up.

Normal behaviour would be to stay on the page with the error message.

Rashid.
GreyHead 26 Feb, 2013
Hi Rashid,

Then your validation isn't working and the form is submitting normally (not inappropriately). Please see this FAQ

Bob
This topic is locked and no more replies can be posted.