在线
客服

发布
需求

天盟
APP

天盟APP下载

关注
微信

微信扫一扫访问
顶部

以下代码我到底是哪里错了,怎么无法横向排列?

无标题文档*{margin:0;padding:0;}.footer{height:470px;                background-color:#333;}.footer-top{width:990px;      height:278px;      border-bottom:1px dotted #555;                        margin:0 auto;}.footer-top h3{width:158px;       line height:50px;                          color:#acaeab;                          font-size:14px;                          font-family:"微软雅黑";}.footer-top ul{color:#acaeab;       height:10px;       line height:10px;       font-size:12px;                          font-family:"微软雅黑";                          font-weight:bolder;}    UC浏览器

   
          
  • 产品动态      
  • 功能介绍      
  • 安卓浏览器      
  • iPhone浏览器      
  • 电脑浏览器      
  • WP浏览器      
  • iPad浏览器      
  • aPad浏览器      
  • TV浏览器      
  • 塞班浏览器   

    UC浏览器

   
          
  • 产品动态      
  • 功能介绍      
  • 安卓浏览器      
  • iPhone浏览器      
  • 电脑浏览器      
  • WP浏览器      
  • iPad浏览器      
  • aPad浏览器      
  • TV浏览器      
  • 塞班浏览器   

    UC浏览器

   
          
  • 产品动态      
  • 功能介绍      
  • 安卓浏览器      
  • iPhone浏览器      
  • 电脑浏览器      
  • WP浏览器      
  • iPad浏览器      
  • aPad浏览器      
  • TV浏览器      
  • 塞班浏览器   

    UC浏览器

   
          
  • 产品动态      
  • 功能介绍      
  • 安卓浏览器      
  • iPhone浏览器      
  • 电脑浏览器      
  • WP浏览器      
  • iPad浏览器      
  • aPad浏览器      
  • TV浏览器      
  • 塞班浏览器   

    UC浏览器

   
          
  • 产品动态      
  • 功能介绍      
  • 安卓浏览器      
  • iPhone浏览器      
  • 电脑浏览器      
  • WP浏览器      
  • iPad浏览器      
  • aPad浏览器      
  • TV浏览器      
  • 塞班浏览器   

    UC浏览器

   
          
  • 产品动态      
  • 功能介绍      
  • 安卓浏览器      
  • iPhone浏览器      
  • 电脑浏览器      
  • WP浏览器      
  • iPad浏览器      
  • aPad浏览器      
  • TV浏览器      
  • 塞班浏览器   


也加过float,但加上去后浏览器上显示的更乱了

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

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

使用道具 举报

全部参与3

把你代码前面的两个样式
.footer{height:470px;background-color:#333;}.footer-top{width:990px;height:278px;border-bottom:1pxdotted#555;margin:0auto;}改为:
.footer{height:470px;background-color:#333;width:990px;margin:0auto;}.footer-top{height:278px;border-bottom:1pxdotted#555;float:left;}

使用道具 举报

要想并排显示首先总宽度要小于或等于对象上级宽度,这样才能并排显示实现横向排列排版布局。
你把.footer-top中的宽度改小,再在后面写上float: left;就行了;
还有你设置的行高line-height里面的“-”没有加上;

使用道具 举报

你是想让li横行排列还是footer-top横向排列呢?

这两个都可以用float方法,但记得清浮动。

使用道具 举报

发新帖
国内首家创新型IT技术需求众包服务平台,软件需求就上天盟网! 立即登录 立即注册