我的问题是第一个旋转木马效果很好,但是第二个却没有。它不希望我单击下一个或上一个。如何动态地更改或单击一页上的图像?
这是我视图中的轮播代码,img src直接插入到数据库中
<div id="carouselExampleControls" class="carousel slide" data-ride="carousel">
<div class="carousel-inner">
<div class="carousel-item active">
//DATABASE IMAGE 1// <img style="width:100%" src="/storage/cover_images/{{$post->cover_image}}">
</div>
<div class="carousel-item">
//DATABASE IMAGE 2// <img style="width:100%" src="/storage/cover_twos/{{$post->cover_two}}">
</div>
<div class="carousel-item">
//DATABASE IMAGE 3// <img style="width:100%" src="/storage/cover_threes/{{$post->cover_three}}">
</div>
</div>
<a class="carousel-control-prev" href="#carouselExampleControls" role="button" data-slide="prev">
<span class="carousel-control-prev-icon" aria-hidden="true"></span>
<span class="sr-only">Previous</span>
</a>
<a class="carousel-control-next" href="#carouselExampleControls" role="button" data-slide="next">
<span class="carousel-control-next-icon" aria-hidden="true"></span>
<span class="sr-only">Next</span>
</a>
</div>