我有一个简单的<a>
标签,其中一个按钮设置为激活一个模态。出于某种原因,它将无法正常工作。我试图手动初始化它,但我没有运气。我试图将href=
字段设置为模态ID,但没有运气。这本周早些时候工作得很好,然后就停止了。它将我重定向到我的页面顶部。有什么想法吗?
情态动词
<div class="modal fade" id="modal-3" tabindex="-1" role="modal" aria-labelledby="modal-label-3" aria-hidden="true">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div class="modal-header">
<button aria-hidden="true" data-dismiss="modal" class="close" type="button">×</button>
<h4 id="modal-label-3" class="modal-title">Large Modal</h4>
</div>
<div class="modal-body">
<div class="row mb20">
<div class="col-sm-12">
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Laudantium atque architecto quae ullam rem labore veritatis temporibus asperiores, ad eaque odit commodi inventore dolore perspiciatis, nam dicta est eos id quod excepturi.</p>
</div>
</div>
<div class="row">
<div class="col-sm-6 xs-box">
<div class="box-services-a">
<h3>Fast processing code</h3>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Nobis maiores repudiandae, accusantium reiciendis!</p>
</div>
</div>
<div class="col-sm-6">
<div class="box-services-a">
<h3>Endless variations</h3>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Nobis maiores repudiandae, accusantium reiciendis!</p>
</div>
</div>
</div>
</div>
<div class="modal-footer">
<button data-dismiss="modal" class="btn btn-b" type="button">Close</button>
<button class="btn btn-b" type="button">Save Changes</button>
</div>
</div>
</div>
</div>
调用它的部分(是的,我正在使用模板。它的POLO V2)
<section>
<div class="col-md-4">
<div class="jumbotron jumbotron-small jumbotron-border">
<h3>Large Modal</h3>
<p>Consectetur adipiscing elit. Morbi sagittis, sem quis lacinia faucibus, orci ipsum gravida tortor, vel interdum mi sapien ut justo. Nulla varius consequat magna, id molestievolutpat. </p>
<a class="button color button-3d rounded effect icon-left" data-target="#modal-3" data-toggle="modal" href="#"><span><i class="fa fa-cloud"></i>Open Large Modal</span></a>
</div>
</div>
</section>