小编mik*_*ike的帖子

在 Woocommerce 中启动和停止 Ajax Overlay 微调器

我开发了自定义支付网关,它将通过ajax延迟处理支付。我想展示目前在 woocommerce 中使用的相同微调器。

这是我的 jQuery 代码的摘录:

function callAjax(){
    jQuery.ajax({
        type : "POST",
        url: '<?php echo site_url().'/?wc-api=custom_ function'; ?>',
        data: response,
        //data: {action:'gateway'},
        dataType : "json",
        cache: false,
        success: function(response) {                               
            //alert("Your vote could not be added");
            //alert(response);
            flag = true;
            // window.location = response.redirect;
            //console.log(response);
            return false;
        }
    }); 
}

setTimeout(
    function(){ callAjax(); 
}, 3000);
Run Code Online (Sandbox Code Playgroud)

所以我想做这个:

请检查图片

如何在结帐页面中启动和停止 ajax Woocommerce 叠加旋转器?

php ajax wordpress jquery woocommerce

7
推荐指数
1
解决办法
3895
查看次数

标签 统计

ajax ×1

jquery ×1

php ×1

woocommerce ×1

wordpress ×1