css 上一期/下一期 Bootstrap 传送带

uyhoqukh  于 2022-12-24  发布在  Bootstrap
关注(0)|答案(1)|浏览(152)

基本上,我尝试做的是去左/右图片,但我的网页移动略低,我甚至试图按照教师就如何做到这一点,但必须有一块代码,我错过了

<div id="testimonial-carousel" class="carousel slide" data-ride="false">
      <div class="carousel-inner">
        <div class="carousel-item active">
          <h2>I no longer have to sniff other dogs for love. I've found the hottest Corgi on TinDog. Woof.</h2>
          <img class="testimonial-image" src="images/dog-img.jpg" alt="dog-profile">
          <em>Pebbles, New York</em>
        </div>
        <div class="carousel-item">
          <h2 class="testimonial-text">My dog used to be so lonely, but with TinDog's help, they've found the love of
            their life. I think.</h2>
          <img class="testimonial-image" src="images/lady-img.jpg" alt="lady-profile">
          <em>Beverly, Illinois</em>
        </div>
      </div>
      <a class="carousel-control-prev" href="#testimonial-carousel" role="button" data-slide="prev">
        <span class="carousel-control-prev-icon"></span>
        <span class="sr-only">Previous</span>
      </a>
      <a class="carousel-control-next" href="#testimonial-carousel" role="button" data-slide="next">
        <span class="carousel-control-next-icon"></span>
        <span class="sr-only">Next</span>
      </a>
    </div>

我希望能够手动查看图片(通过点击它们)与上一步/下一步按钮

idfiyjo8

idfiyjo81#

问题是我引用的(href)是内部链接而不是脚本

<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/js/bootstrap.bundle.min.js"></script>

我一定是沿着移动文件夹的过程中不小心替换了这个(因为我大多引用链接,不使用本地库)。

相关问题