gpt4 book ai didi

jquery - Bootstrap 3 带按钮的旋转木马

转载 作者:可可西里 更新时间:2023-11-01 13:34:01 27 4
gpt4 key购买 nike

我是 bootstrap 3 的新手,正在为我的网站制作轮播。我需要创建一个具有“淡入淡出”效果的旋转木马和旋转木马下方的 4 个按钮,单击这些按钮会触发图像之间的转换。我不想使用 Bootstrap API 提供的默认控件(左/右箭头和指示器)。

我想创建这样的东西 - https://moodle.org/

到目前为止,这是我的代码 -

<!DOCTYPE html>
<html lang="en"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="">
<meta name="author" content="">

<title>Carousel Template for Bootstrap</title>

<link href="http://getbootstrap.com/dist/css/bootstrap.css" rel="stylesheet">

<link href="carousel.css" rel="stylesheet">



</head>
<body style="padding-left: 50px;padding-right: 50px;">
<div id="myCarousel" data-interval="false" class="carousel slide" data-ride="carousel" >

<div class="carousel-inner">
<div class="item active">
<img alt="First slide" src="1.jpg">
<div class="container">
<div class="carousel-caption">
<h1>Example headline.</h1>
</div>
</div>
</div>
<div class="item">
<img alt="Second slide" src="1.jpg">
<div class="container">
<div class="carousel-caption">
<h1>Another example headline.</h1>
</div>
</div>
</div>
<div class="item">
<img alt="Third slide" src="1.jpg">
<div class="container">
<div class="carousel-caption">
<h1>One more for good measure.</h1>
</div>
</div>
</div>
</div>
<a class="left carousel-control" href="#myCarousel" data-slide="prev"><span class="glyphicon glyphicon-chevron-left"></span></a>
<a class="right carousel-control" href="#myCarousel" data-slide="next"><span class="glyphicon glyphicon-chevron-right"></span></a>

</div><!-- /.carousel -->

<div align="center">
<p>Carousel with auto-slide disabled!</p>
</div>



<!-- FOOTER -->
<footer>
<p class="pull-right"><a href="http://getbootstrap.com/examples/carousel/#">Back to top</a></p>
<p>© 2014 Company, Inc. · <a href="http://getbootstrap.com/examples/carousel/#">Privacy</a> · <a href="http://getbootstrap.com/examples/carousel/#">Terms</a></p>
</footer>

</div><!-- /.container -->




<script src="./Carousel Template for Bootstrap_files/jquery.min.js"></script>
<script src="./Carousel Template for Bootstrap_files/bootstrap.min.js"></script>
<script src="./Carousel Template for Bootstrap_files/docs.min.js"></script>



</body></html>

最佳答案

您可以使用 Bootstrap 尝试这样的事情..

http://bootply.com/113737

它使用 data-targetdata-slide-to 导航到特定幻灯片。

关于jquery - Bootstrap 3 带按钮的旋转木马,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21777871/

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