HTML按钮按下其中一个按钮后停止工作

时间:2018-05-02 21:22:23

标签: html button nav

我有这4个按钮,如果它是第一个被按下的话,每个按钮都有效,但按下其中一个后所有按钮都停止工作。

<nav class="navbar navbar-expand-lg navbar-dark fixed-top" id="mainNav">
  <div class="container">
    <a class="navbar-brand js-scroll-trigger" href="#page-top">BusTracker</a>
    <button class="navbar-toggler navbar-toggler-right" type="button" data-toggle="collapse" data-target="#navbarResponsive" aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation">
          Menu
          <i class="fa fa-bars"></i>
        </button>
    <div class="collapse navbar-collapse" id="navbarResponsive">
      <ul class="navbar-nav text-uppercase ml-auto">
        <li class="nav-item active">
          <a class="nav-link js-scroll-trigger" href="#services">Serviços</a>
        </li>
        <li class="nav-item active">
          <a class="nav-link js-scroll-trigger" href="#about">Sobre nós</a>
        </li>
        <li class="nav-item active">
          <a class="nav-link js-scroll-trigger" href="#team">Equipa</a>
        </li>
        <li class="nav-item active">
          <a class="nav-link js-scroll-trigger" href="#faq">FAQ</a>
        </li>
    </div>
  </div>
</nav>

0 个答案:

没有答案