2727551894

导航

 

【jQuery】 Ajax 

  $.ajax({
        type: "Post",   // 发包方式
        cache: false,   // 是否缓存
        contentType: "application/json",  // 发送数据类型 data 的类型
        url: @url,  // 发包链接
        data: @date,  // 发包内容
        dataType: "json",  // 返回结果数据类型
        async: false,  // false 为同步, true 为异步
        success: function (s) {
           //doSuccess(s); // 成功后的回掉函数
        },
        error: function (e) {
            //doError(s);  // 异常后的回掉函数
        }
    });

 

 
posted on 2014-12-16 14:55  xmj112288  阅读(243)  评论(0编辑  收藏  举报