function deldata(order_id){
confirm_ = confirm('真的要删除吗.....');
if(confirm_){
$.ajax({
type:"GET",
url:'__URL__/del/id/'+order_id,
success:function(msg){
alert(msg);
//all delete is success,this can be execute
//$("#tagid"+order_id).remove();
},
error:function(data){
alert(data);
}
});
}
};
public function del(){
$db = M('Person');
$db->delete($_GET['id']);
$this->ajaxReturn(1,'删除成功',1);
}
返回数据为什么是error,而不是success但删除是成功的 最佳答案
