Google Captcha and posted positive validation


I have set Multiform Recaptcha. How to validate Google variable as positive that content cannot be posted?

Can be improved this code as there are two captcha designs and need to pass variables into PHP variable like
$smarty->assign("gcaptcha", $gcatcha);

How to receive POST value in this case ($gcatcha)?

Need help



  <title>gCaptcha and Multiforms design</title>

<form id="mycontactform1" method="post">


function IsRecapchaValid()
  var res = grecaptcha.getResponse(form);
  if (res == "" || res == undefined || res.length == 0)
    return false;
  return true;

var recaptcha1;
var recaptcha2;
var myCallBack = function() {
  recaptcha1 = grecaptcha.render('recaptcha1',
    'sitekey': 'XXX',
    'theme': 'light'

  recaptcha2 = grecaptcha.render('recaptcha2',
    'sitekey': 'XXX',
    'theme': 'dark'
<script src="" async defer></script>

<input type="submit" name="formsubmit1" data-callback="captchaSubmit" value="Send" class="" />




This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.