swal()弹出删除确认框
生活随笔
收集整理的這篇文章主要介紹了
swal()弹出删除确认框
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
//<a class='btn btn-mini btn-danger' title="刪除" οnclick="delGridBuilding('${bo.id }');"><i class='icon-trash'></i></a>function delGridBuilding(poid) {swal({title : "Are you sure?",text : "確定要刪除嗎?",type : "warning",showCancelButton : true,confirmButtonColor : '#DD6B55',confirmButtonText : 'Yes',cancelButtonText : "No",closeOnConfirm : false},function(isConfirm) {if (isConfirm) {$.ajax({url : '',type : 'post',data : 'id=' + poid,dataType : 'json',async : false,success : function(d) {if (d) {swal({title : "YES",text : "操作成功!",type : "success",}, function() {window.location.reload();});} else {swal("No", "刪除失敗,請稍后再試!", "error");}},error : function(d) {swal("No", d, "error");}});}});}
ミ(ノ゜д゜
總結
以上是生活随笔為你收集整理的swal()弹出删除确认框的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: win7下运行.php,Win7下在II
- 下一篇: 绕过滑块验证码登陆网站的实现