Bootstrap 3 - 从另一个模态打开模态 [英] Bootstrap 3 - open modal from another modal

查看:153
本文介绍了Bootstrap 3 - 从另一个模态打开模态的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以在 Bootstrap 3 从另一个模态打开模态?我有模态窗口,内容从外部html文件加载。

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


  1. 我正在打开模态窗口。在那里,我有一个表单要提交。

  2. 点击提交按钮后,我想用新的模态窗口(以及另一个html文件的新内容)进入下一步。 / li>
  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.

我试图使用 data-dismiss =提交按钮上的模态 data-toggle =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.

推荐答案

你可以使用 http://jschr.github.io/bootstrap-modal/bs3.html ;检查可堆叠的例子。

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

这篇关于Bootstrap 3 - 从另一个模态打开模态的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆