Answer the question
In order to leave comments, you need to log in
How to check google captcha with ajax?
Hello. Tell me please. There is a mold
<form action="/callback/" id="fastBuyFormBasket" method="GET">
<div class="formLine"><input name="name" type="text" placeholder="Имя*" value="" id="fastBuyFormNameBasket"></div>
<div class="formLine"><input name="phone" type="text" placeholder="Телефон*" value="" id="fastBuyFormTelephoneBasket"></div>
<div id="recaptcha2"></div>
<div class="formLine"><a href="#" id="fastBuyFormSubmitBasket">Заказать</a></div>
</form>
var sendFastBackBasket = function(event){
var $fastBuyForm = $("#fastBuyFormBasket");
var $fastBuyFormName = $fastBuyForm.find("#fastBuyFormNameBasket").removeClass("error");
var $fastBuyFormTelephone = $fastBuyForm.find("#fastBuyFormTelephoneBasket").removeClass("error");
if($fastBuyFormName.val() == ""){
$fastBuyFormName.addClass("error");
}
if($fastBuyFormTelephone.val() == ""){
$fastBuyFormTelephone.addClass("error");
}
if($("#recaptcha-anchor").attr("aria-checked", false){
console.log("error");
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question