0

I am using Bootswatch Cosmo to build my website, but the dropdown menu isn't working. You can view the page live at http://spencermehta.co.uk. The html is:

<nav class="navbar navbar-default navbar-fixed-top">
  <div class="container">
    <div class="navbar-header">
      <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navigationbar">
        <span class="sr-only">Toggle navigation</span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
      </button>
      <a class="navbar-brand" href="../">Spencer Mehta</a>
    </div>

    <div class="collapse navbar-collapse" id="navigationbar">
      <ul class="nav navbar-nav">
        <li class="dropdown">
          <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">Projects
          <span class="caret"></span></a>
          <ul class="dropdown-menu" role="menu">
            <li><a href="../spenbot/">Spenbot</a></li>
          </ul>
        </li>
        <li><a href="/contact">Contact</a></li>
      </ul>
      <ul class="nav navbar-nav navbar-right">
        <li><a href="http://twitter.com/spencermehta" target=_blank>Twitter</a></li>
        <li><a href="http://twitch.tv/spencermehta" target=_blank>Twitch</a></li>
        <li><a href="http://imraising.com/spencermehta" target=_blank>Donate</a></li>
      </ul>
    </div>
  </div>
</nav>
4

1 回答 1

4

确保您已添加 jquery 和 bootstrap.js 文件并且它们的路径正确。

于 2015-04-12T12:25:33.107 回答