<script src="js/bootbox.all.min.js"></script>
<button id="btn_ydilkaydet_" onclick="sinavyerisec();return false;" value="Seçimi Kaydet" class="btn btn-primary" style="width: 130px"></button>
<asp:Button ID="btn_ydilkaydet" runat="server" Text="Kaydet" style="display:none" OnClick="btn_ydilkaydet_Click" />
function sinavyerisec() {
var ms = "<br>Bu bilgiler kaydedilsin mi?<br>";
bootbox.confirm({
message: ms,
buttons: {
confirm: {
label: 'Kaydet',
className: 'btn-primary'
},
cancel: {
label: 'Vazgeç',
className: 'btn-warning'
}
},
callback: function (result) {
//if(result){}
//window.open('<%= ConfigurationManager.AppSettings["failurlsi"] %>');
$("[id$='btn_ydilkaydet']").click();
}
});
}
veya
bootbox.confirm("This is the default confirm!", function(result){
console.log('This was logged in the callback: ' + result);
});
//ALERT
bootbox.alert("This is the default alert!");
bootbox.alert({
message: "This is an alert with a callback!",
callback: function () {
console.log('This was logged in the callback!');
}
});