小编Nic*_*nou的帖子

使用Jquery进行Google重新验证

我有兴趣在用户打勾并验证google recaptcha后立即隐藏resultcaptcha消息.只有第一部分(v.length == 0)有效.否则如果不起作用.你可以在这里查看表格:https://csandreas1.herokuapp.com

if(grecaptcha.getResponse() == 0) // this works
    {
        $('#resultcaptcha').show();
        $('#resultcaptcha').html('<i class="fa fa-exclamation-circle w3-text-red fa-3x" aria-hidden="true"></i> <span class="w3-text-white w3-bold" style="font-size:16px"> Please verify that you are a human</span>');
    }
    else if(grecaptcha.getResponse() == 1)//this doesn't work
    {
        $('#resultcaptcha').hide();
        $('#resultcaptcha').html('');
    }

    else{//submit the form}
Run Code Online (Sandbox Code Playgroud)

javascript jquery recaptcha

2
推荐指数
1
解决办法
1728
查看次数

标签 统计

javascript ×1

jquery ×1

recaptcha ×1