Bootstrap:在Modal中打开另一个模态
所以,我正在使用此代码在当前打开的模态窗口中打开另一个模态窗口:
So, I'm using this code to open another modal window in a current opened modal window:
<a onclick=\"$('#login').modal('hide');$('#lost').modal('show');\" href='#'>Click</a>
会发生的情况是,对于类似500ms的滚动条将会复制。我猜是因为目前的模态还在逐渐淡出。然而,它看起来非常不平滑和口吃。
What happens is, that for like 500ms the scrollbar will duplicate. I guess because the current modal is still fading out. However it looks very un-smooth and stuttering.
我将不胜感激任何解决此问题的建议。
I would appreciate any suggestions to solve this issue.
另外,在onclick-event unprofessional中建立这个的方式是什么?
Also, is the way building this in an onclick-event unprofessional?
我正在使用bootstrap 3.0版。
I'm working with the bootstrap version 3.0.
编辑:我想减少淡出模态的时间是必要的。这怎么可能?
data-dismiss
使当前模态窗口强制关闭
data-dismiss
makes the current modal window force close
data-toggle
打开一个带有 href
里面的内容
data-toggle
opens up a new modal with the href
content inside it
<a data-dismiss="modal" data-toggle="modal" href="#lost">Click</a>
或
<a data-dismiss="modal" onclick="call the new div here">Click</a>
请告诉我们是否有效。
- 您可能还想查看模态文档