Bootstrap 3 - open modal from another modal

时光怂恿深爱的人放手 提交于 2019-12-29 04:23:08

问题


Is it possible in Bootstrap 3 to open modal from another modal? I have modal windows with content loaded from external html files.

  1. I'm opening the modal window. There I have a form to submit.
  2. After clicking the submit button I would like to go to the next step with a new modal window (and a new content from another html file).

As far as I know you can't have two modal windows simultaneously, so I have to close the first modal and then open the second one. The problem is I have to do after clicking the submit button in the first modal.

I've tried to use the data-dismiss="modal" with data-toggle="modal" attributes on the submit button but they only hide the first modal, the background in still dark and nothing happens.


回答1:


you can use http://jschr.github.io/bootstrap-modal/bs3.html for that; check stackable example.



来源:https://stackoverflow.com/questions/23931131/bootstrap-3-open-modal-from-another-modal

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!