Bootstrap下拉列表在页面加载时展开

时间:2014-12-12 09:56:17

标签: javascript html twitter-bootstrap

我有一个Bootstrap下拉列表。页面加载后,菜单将展开。我怎样才能解决这个问题?

这是截图和代码:

enter image description here

    <div class="col-lg-3">
       <div class="bs-component">
          <ul class="nav nav-pills nav-stacked">
            <li class="dropdown open">
              <a id="ModelFilter" class="dropdown-toggle" data-toggle="dropdown" href="#" aria-expanded="true">
                Dropdown <span class="caret"></span>
              </a>
              <ul class="dropdown-menu">
                <li><a href="#">Action</a></li>
                <li><a href="#">Another action</a></li>
                <li><a href="#">Something else here</a></li>
                <li class="divider"></li>
                <li><a href="#">Separated link</a></li>
              </ul>
            </li>
          </ul>
       </div>
    </div>

1 个答案:

答案 0 :(得分:4)

open元素

中删除课程<li>
<li class="dropdown"> ... </li>