I'm using the following code (via '[Dark Side of the Carton][1]') to validate a reCAPTCHA field, **before** submitting the rest of a form that includes the captcha field.
The validation works fine, the 'recaptchavalidate' page is called, returns *True* or *False* correctly and the JavaScript picks this all up (I test this via *alert(html);*).
However, when *True*, the form doesn't continue to be sumbitted as you would expect. In fact, even worse, the reCAPTCHA refreshes as if the response was wrong.
I think it's my JavaScript at fault rather than the reCAPTCHA ... but where am I going wrong?
**EDIT**: This is used only to check there are no errors before submitting. The reCAPTCHA is checked properly after submitting (via Python, not JS). So is not as big a security hole as some users have pointed out.
[1]: http://www.darksideofthecarton.com/2008/12/15/validating-recaptcha-with-jquery-and-ajax/comment-page-1/
以上就是jQuery form validation problem.的详细内容,更多请关注web前端其它相关文章!