$(document).ready(function() {
$.get('/Index/checkdo/id/{$id}',function(ret){
retime_flag = 0;
$('#time').html('');
if(ret == 'movesay'){
$('#msg').html('OK 检查通过,跳转中...');
if(returnurl){
setTimeout(function() {
window.location.href= returnurl;
},1000);
}else{
setTimeout(function() {
window.location.href= '/';
},1000);
}
}else{
$('#load_img').hide();
$('#msg').html('检查未通过!!!');
}
});
});
求大神,关于js $.get()的用法
- 写回答
- 好问题 0 提建议
- 关注问题
- 邀请回答
-
5条回答 默认 最新
Lee_Y_K 2016-05-04 09:42关注完整的四个参数.
$.get([地址] , [请求参数,get 方法是queryString] , [回调方法, function(结果参数){ }] , [响应类型, json, text 等, 不正确的类型不会执行回调方法, 可不填写默认text])本回答被题主选为最佳回答 , 对您是否有帮助呢?解决 无用评论 打赏 举报