* Bootstrap - モーダルウィンドウ [#tae03184]
** モーダルウィンドウでOKを選んだらPOSTする [#zc8de23b]
- http://stackoverflow.com/questions/17508444/how-to-post-the-data-from-a-modal-form-of-bootstrap
- http://untame.net/2013/05/how-to-build-a-modal-contact-form-in-twitter-bootstrap-with-php-ajax/
** Bootboxjs [#id8a4322]
http://bootboxjs.com/
$(function () {
$("input[data-kind='confirm-btn'").on('click', function (e) {
e.preventDefault();
var form = this.form;
var text = $(this).data('text');
bootbox.dialog({
message: text,
buttons: {
confirm: {
label: "OK",
className: "btn-primary",
callback: function (ret) {
if (ret) {
callback: function (data) {
if (data) {
form.submit();
}
}
},
cancel: {
label: "Cancel",
className: "btn-default",
callback: function () { }
}
}
});
});
});
<input data-kind="confirm-btn" data-text="登録しますか?" type="submit" value="登録" />
http://bootboxjs.com/
** 参考 [#nfc077da]
http://getbootstrap.com/javascript/#modals