29 ноя 2019 web it game lab Программисты ПК , айфон, андроид :
Нужна помощь есть скрипт вордпресс
Скрипт выглядит следующим образом , мне необходимо чтоб он работал после Аякс запроса и не отваливался
$(document).ready(function(){
$('.ajax_post_form, .exbajaxpostform').ajaxForm({
dataType: 'json',
beforeSubmit: function(a,f,o) {
f.addClass('thisactive');
$('.thisactive input[type=submit], .thisactive input[type=button]').attr('disabled',true);
$('.thisactive').find('.ajax_submit_ind').show();
},
success: function(ht) {
if(ht['otv'] == 'error'){
$('.thisactive .resultgo').html('<div class="exbresfalse"><div class="exbresclose"></div>'+ht['text']+'</div>');
}
if(ht['otv'] == 'success'){
$('.thisactive .resultgo').html('<div class="exbrestrue"><div class="exbresclose"></div>'+ht['text']+'</div>');
}
if(ht['otv'] == 'success_clear'){
$('.thisactive .resultgo').html('<div class="exbrestrue"><div class="exbresclose"></div>'+ht['text']+'</div>');
$('.thisactive input[type=text], .thisactive input[type=password], .thisactive textarea').attr('value','');
}
if(ht['url']){
window.location.href = ht['url'];
}
<?php do_action('ajax_post_form_jsresult'); ?>
$('.thisactive input[type=submit], .thisactive input[type=button]').attr('disabled',false);
$('.thisactive').find('.ajax_submit_ind').hide();
$('.thisactive').removeClass('thisactive');
}
});
});
<?php do_action('ajax_post_form_jsresult'); ?> и как найти где находится этот скрипт не пойму. Сообщество: web it game lab Программисты ПК , айфон, андроид
Канал: Программирование
56 0 1 2
Комментарии (2)
ponikigogo
10 дек 2019
Скрипт с пабла такой достал пхп плюс js но я его уже переделал на Аякс на вордпресе он все перебрал и плагин и шаблон
0
Для добавления комментариев необходимо авторизоваться
Наследие Хаоса
Начало летописи о первых воинах ступивших на землю....