// $errorsAndAlerts .= "Thanks, we've emailed you instructions on resetting your password.<br/><br/> If you don't receive an email within a few minutes check your spam filter for messages from elvis himself<br/>\n";

If i click submit without completing anything i have both the warning of "Please check the anti-spam 'I am not a robot' checkbox!" AND "No email specified!"

Were I to just click the Googles "I am not a robot" recaptcha error,,,, I get the "No email specified!" alert

but were I to NOT CHECK the captcha, and just enter a correct email address, on this occasion enter emmalinnery@gmail.com, then it goes through. I want it so when the correct email is entered and captcha is not checked to have the alert show "Please check the anti-spam 'I am not a robot' checkbox!"

// $errorsAndAlerts .= "Thanks, we've emailed you instructions on resetting your password.<br/><br/> If you don't receive an email within a few minutes check your spam filter for messages from elvis himself<br/>\n";

Hmm, I'm not sure by looking at the code. I don't see any obvious errors. A quick and easy debugging technique would be put some print statements to see what the contents of $errorsAndAlerts is at various points and then try and determine where the variable is either not getting set, or getting overwritten.

Hope that helps!

Dave Edis - Senior Developer
interactivetools.com

Newsletter

New features, products, web development news, special limited time promotions, and more. Read Latest

Enter your email address:

Your email will only be used for the interactivetools.com Newsletter
(privacy policy).