keithg

Google Recaptcha validation with javascript and php

javascript: function validateform(){ var captcha_response = grecaptcha.getResponse(); if(captcha_response.length == 0) { // Captcha is not Passed return false; } else { // Captcha is Passed return true; } } // ]]> PHP if(empty(g-recaptcha-response)) { echo ‘You can not pass the blank captcha code’; }Read more …