[css layout][06] three percentage columns
2013-11-11 20:10
351 查看
![](http://images.cnitblog.com/blog/472709/201311/11195550-4c4e8c82fbe94a9184572679a626b250.png)
1.#wrapper宽度100%全部float向左
#wrapper { width: 100%; float: left; } #content { margin-left: 50%; } #navigation { float: left; width: 25%; margin-left: -75%; } #extra { float: left; width: 25%; margin-left: -100%; } #footer { clear: both; }
2.#wrapper宽度100%全部float向右
#wrapper { width: 100%; float: right; } #content { margin-left: 50%; } #navigation { float: right; width: 25%; margin-right: -50%; } #extra { float: right; width: 25%; margin-right: -25%; } #footer { clear: both; }
3.#wrapper宽度50%全部float向右
#wrapper { width: 50%; float: right; } #navigation { float: right; width: 25%; } #extra { float: right; width: 25%; } #footer { clear: both; }
4.#wrapper宽度50%全部float向左
#wrapper { width: 50%; float: left; margin-right: -50%; position: relative; left: 50%; } #navigation { float: left; width: 25%; margin-right: -25%; position: relative; left: 25%; } #extra { float: left; width: 25%; } #footer { clear: both; }
相关文章推荐
- [css layout][02] three percentage columns
- [css layout][03] three percentage columns
- [css layout][04] three percentage columns
- [css layout][05] three percentage columns
- [css layout][01] three percentage columns
- [css layout][21]Liquid, three columns, hybrid widths
- [css layout][09] three fixedcolumns
- [css layout][22]Liquid, three columns, hybrid widths
- [css layout][10] three fixed columns
- [css layout][11] three fixed columns
- [css layout][19]Liquid, three columns, hybrid widths
- [css layout][20]Liquid, three columns, hybrid widths
- three.js 03-06 之 RectAreaLight 光源
- [转]how to split the ng-repeat data with three columns using bootstrap
- [css layout][13] Liquid, secondary columns fixed-width
- [css layout][14]Liquid, secondary columns fixed-width
- three.js 06-03 之 ExtrudeGeometry 高级几何体
- [css layout][15]Liquid, secondary columns fixed-width
- three.js 06-05 之 ParametricGeometry 几何体
- [css layout][23]Two columns liquid, side fixed