快捷导航

关于bootstrap 2-7项目作业下拉菜单显示的问题

下拉菜单变形,如何将其恢复横向显示?

变成视频中演示的这种样式:

我的源代码是:


   
        
        
        
        2-7
        
        
        
        

   
   
        
        
            
               
                    
                        

                    

                    
                        Toggle navigation
                        
                        
                        
                    
                    
                    
                        

                               
  • 首页 (current)
                               

  •                                 生日
                                        

                                    

                                          
    • Action
                                          
    • Another action
                                          
    • Something else here
                                          

    •                                     
    • Separated link
                                          

    •                                     
    • One more separated link
                                      

                               

  •                                 婚礼
                                        

                                    

                                          
    • Action
                                          
    • Another action
                                          
    • Something else here
                                          

    •                                     
    • Separated link
                                          

    •                                     
    • One more separated link
                                      

                               

  •                                 专用
                                        

                                    

                                          
    • Action
                                          
    • Another action
                                          
    • Something else here
                                          

    •                                     
    • Separated link
                                          

    •                                     
    • One more separated link
                                      

                               

  •                                 商铺
                                        

                                    

                                          
    • Action
                                          
    • Another action
                                          
    • Something else here
                                          

    •                                     
    • Separated link
                                          

    •                                     
    • One more separated link
                                      

                            

                    

                    
                        
                        
                        
                    

               

            
        
        
        
        
   



layout.css里的样式是:
@charset "utf-8";
.head-msg{
    float: right;
    height: 50px;
    line-height: 50px;
    text-align: center;
}
.head-msg > span{
    width: 45px;
    color: #FFFFFF;
}
.navbar-default{
    background: #5d4b33;
    border: none;
    border-radius: 0;
}
.navbar-header,.navbar-toggle{
    float: left;
}
.navbar-default .navbar-toggle .icon-bar{
    background-color: #fff;
}
.navbar-default .navbar-toggle{
    background-color: #f0781a;
}
.navbar-brand img{
    margin-top: -8px;
}
.container-fluid > .navbar-collapse{
    float: left;
}

免责声明:本内容仅代表回答者见解不代表本站观点,请谨慎对待。

版权声明:作者保留权利,不代表本站立场。

回复

使用道具 举报

参与会员1

使用绝对定位
回复

使用道具 举报

可能感兴趣的问答

发新帖
  • 微信访问
  • 手机APP