From 67d07ca591af6abe477353c76ca4ca7a32cbde7f Mon Sep 17 00:00:00 2001 From: Alexander Grebennik <aleks.grebennik@gmail.com> Date: Mon, 30 Jul 2012 11:25:56 +0300 Subject: [PATCH] added ability to reload modal content on each modal show --- js/bootstrap-modal.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/js/bootstrap-modal.js b/js/bootstrap-modal.js index 530b53e07e..02595463df 100644 --- a/js/bootstrap-modal.js +++ b/js/bootstrap-modal.js @@ -49,6 +49,8 @@ if (this.isShown || e.isDefaultPrevented()) return + !this.options.cache && this.$element.find('.modal-body').load(this.options.remote) + $('body').addClass('modal-open') this.isShown = true @@ -206,6 +208,7 @@ backdrop: true , keyboard: true , show: true + , cache: true } $.fn.modal.Constructor = Modal @@ -226,4 +229,4 @@ }) }) -}(window.jQuery); \ No newline at end of file +}(window.jQuery); -- GitLab