Merge pull request #271 from cvogeley/master
Confirm box: fall back to standard js confirm dialog if bootstrap isn't ...
This commit is contained in:
commit
d0e657f0f0
@ -309,11 +309,16 @@ function enableOnUser(){
|
||||
<script>
|
||||
$( document ).on( "click", ".wall-item-delete-link,.page-delete-link,.layout-delete-link,.block-delete-link", function(e) {
|
||||
var link = $(this).attr("href"); // "get" the intended link in a var
|
||||
|
||||
if (typeof(eval($.fn.modal)) === 'function'){
|
||||
e.preventDefault();
|
||||
bootbox.confirm("<h4>{{$confirmdelete}}</h4>",function(result) {
|
||||
if (result) {
|
||||
document.location.href = link;}
|
||||
});
|
||||
});}
|
||||
else {
|
||||
return confirm("{{$confirmdelete}}");
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
|
Reference in New Issue
Block a user