对齐宽度相等的列表项

时间:2014-06-26 08:12:57

标签: twitter-bootstrap-3

我想对齐所有相等宽度的列表项.... 以下是jsfiddle代码: http://jsfiddle.net/277Yd/

提前致谢

<div class="row">
    <div class="col-sm-2 text-center ">Courses</div>
    <div class="col-sm-2 text-center oval-shape img-responsive">
        <a>Post Graduate</a>
    </div>
    <div class="col-sm-2 text-center oval-shape img-responsive">
        <a>Graduate</a>
    </div>
    <div class="col-sm-2 text-center oval-shape img-responsive">
        <a>Honours</a>
    </div>
    <div class="col-sm-2 text-center oval-shape img-responsive">
        <a>Tiger Studio</a>
    </div>
    <div class="col-sm-2 text-center oval-shape img-responsive">
        <a>Others</a>
    </div>
</div>

.oval-shape a {
    background: #FF9900;
    border-radius:50px;
    padding:10px;
    /*      background-image: url('../images/button.png');
    background-repeat:repeat-x; */
}

1 个答案:

答案 0 :(得分:0)

从CSS中删除a,而不是.oval-shape a {.oval-shape {

width课程中添加oval-shape以调整宽度,例如width:15%;

Updated fiddle