gpt4 book ai didi

jquery - Bootstrap 3.3.7 - 轮播不显示标有类的 div 内容 - 'item'

转载 作者:行者123 更新时间:2023-12-01 06:11:12 24 4
gpt4 key购买 nike

我创建了一个简单的页面,其中仅包含一个 Bootstrap 轮播。

我已经包含了以下脚本文件

  • bootstrap.css
  • jquery-1.11.1.min.js
  • bootstrap.js

问题:我只能看到图像滑动。具有“item”类的 div 的其他内容未出现在幻灯片上。我想在图像上添加其他内容以添加更多描述。就像 this链接。

但我看不到其他内容,只能看到滑动的图像。我是否缺少任何样式表或 js 文件?

 <body>
<div>
<div class="container">
<div id="myCarousel" class="carousel slide" data-ride="carousel">
<!-- Indicators -->
<ol class="carousel-indicators">
<li data-target="#myCarousel" data-slide-to="0" class=""></li>
<li data-target="#myCarousel" data-slide-to="1" class="active"></li>
<li data-target="#myCarousel" data-slide-to="2" class=""></li>
</ol>
<div class="carousel-inner" role="listbox">
<div class="item">
<img class="first-slide" src="" alt="First slide">
<div class="container">
<-- I cant see below divs !-->
<div class="carousel-caption">
<h1>Example headline.</h1>
<p>Note: If you're viewing this page via a <code>file://</code> URL, the "next" and "previous" Glyphicon buttons on the left and right might not load/display properly due to web browser security rules.</p>
<p><a class="btn btn-lg btn-primary" href="#" role="button">Sign up today</a></p>
</div>
</div>
</div>
<div class="item active">
<img class="second-slide" src="" alt="Second slide">
<div class="container">
<div class="carousel-caption">
<h1>Another example headline.</h1>
<p>Cras justo odio, dapibus ac facilisis in, egestas eget quam. Donec id elit non mi porta gravida at eget metus. Nullam id dolor id nibh ultricies vehicula ut id elit.</p>
<p><a class="btn btn-lg btn-primary" href="#" role="button">Learn more</a></p>
</div>
</div>
</div>
<div class="item">
img class="third-slide" src="" alt="Third slide">
<div class="container">
<div class="carousel-caption">
<h1>One more for good measure.</h1>
<p>Cras justo odio, dapibus ac facilisis in, egestas eget quam. Donec id elit non mi porta gravida at eget metus. Nullam id dolor id nibh ultricies vehicula ut id elit.</p>
<p><a class="btn btn-lg btn-primary" href="#" role="button">Browse gallery</a></p>
</div>
</div>
</div>
</div>
<a class="left carousel-control" href="#myCarousel" role="button" data-slide="prev">
<span>Letf</span>
<span class="sr-only">Previous</span>
</a>
<a class="right carousel-control" href="#myCarousel" role="button" data-slide="next">
<span class="" aria-hidden="true"></span>
<span class="sr-only">Next</span>
</a>
</div>
</div>
</div>
</body>

这里是jsfiddle链接。

最佳答案

检查代码的第三部分

\"img class="third-slide"src=""alt="第三张幻灯片">"

您错过了插入“<”... http://prntscr.com/hjaonu

关于jquery - Bootstrap 3.3.7 - 轮播不显示标有类的 div 内容 - 'item',我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47650127/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com