960 GridSystem, three grid_4 inside one grid_12

此生再无相见时 提交于 2019-12-08 01:08:53

问题


I've created a 16 column layout with 960gs with a div class="grid_12" (main) and after that grid_4 (right) (12+4...) Inside that grid_12 I wanted a three column style (3 pcs. grid_4). But the grid_4 boxes don't fit inside the grid_12, the last box drop into a second row.

Shouldn't the 960gs framework be able to do this layout for me, have i missed anything?

Thanks in advance.

<div class="container_16">
...
<div id="main" class="grid_12">
 <div class="grid_12">
   <div class="grid_4"></div>
   <div class="grid_4"></div>
   <div class="grid_4"></div>
 </div>

 <div id="right" class="grid_4">

 </div>
</div>
...
</div>

回答1:


Found out that I needed to add alpha and omega classed to the first and last grid_4 box. Now it works.

<div id="main" class="grid_12">
    <div class="grid_4 alpha">

    </div>
    <div class="grid_4">

    </div>
    <div class="grid_4 omega">

    </div>
</div>


来源:https://stackoverflow.com/questions/2903944/960-gridsystem-three-grid-4-inside-one-grid-12

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!