【问题标题】:How to align images in responsive design如何在响应式设计中对齐图像
【发布时间】:2014-04-25 14:20:22
【问题描述】:

我正在尝试在响应式设计中对齐图像。第一张图片应该左对齐,右对齐,中间对齐——它们之间的间距均匀。

在固定宽度布局中执行此操作很容易,但它不是响应式的。很高兴得到关于这个的任何想法。

谢谢!

http://www.bootply.com/132522

【问题讨论】:

    标签: responsive-design twitter-bootstrap-3


    【解决方案1】:
    ul {
      text-align: center;
      padding: 0;
      margin: 0;
    }
    
    li{
      /*float: left;*/ <- Remove!
      display: inline;
      list-style: none;
    }
    
    li:first-child {
        float: left; 
    }
    
    li:last-child {
        float: right; 
    }
    

    【讨论】:

      猜你喜欢
      • 2013-09-08
      • 2013-04-14
      • 2016-10-06
      • 1970-01-01
      • 2012-12-21
      • 2018-03-23
      • 2014-10-12
      • 1970-01-01
      • 2014-06-24
      相关资源
      最近更新 更多