Bootstrap 3 - 悬停时的下拉菜单项不显示内容

时间:2015-02-22 18:40:30

标签: javascript jquery html css twitter-bootstrap

我的下拉菜单(带有地图img的菜单)不起作用,它应显示名为dropdown的类中的内容。非常感谢你的帮助。

Problem menu item

<header class="navbar-fixed-top">
<div id="menu-top">
    <div class="container">
        <div class="col-xs-12 col-sm-12 col-md-8 col-lg-8">
            <h2 class="head-text">ATS GLOBAL - {$txt_head1}</h2>
        </div>
        <div class="col-xs-12 col-sm-12 col-md-4 col-lg-4">
                  <ul class="nav navbar-nav">
                    <li class="dropdown"><a href="" data-hover="dropdown"><img src="/images/images/mapimg.png" alt="" /> <span class="caret"></span></a>
                      <ul class="dropdown-menu">
                        <li><a href="#">programowanie</a></li>
                        <li><a href="#">grafika</a></li>
                        <li><a href="#">wideo</a></li>
                        <li><a href="#">DTP</a></li>
                      </ul>
                    </li>
                  </ul>
        </div>           
    </div>    
</div>
.....

1 个答案:

答案 0 :(得分:0)

将此添加到您的css

.dropdown {
  background: url( "/images/images/mapimg.png") no-repeat;
  display: block;
  height: 100px; //Your image's height
}