Vertical align in bootstrap 3


Vertical align in bootstrap 3 : You can vertical align in bootstrap by using your own custom classes as below.


Vertical align in bootstrap 3 Example

Let’s Create separate classes for vertical align in bootstrap

.vertical-center {
    display: inline-block;
    vertical-align: middle !important;
    float: none;
}
.vertical-top {
    display: inline-block;
    vertical-align: top !important;
    float: none;
}
.vertical-bottom {
    display: inline-block;
    vertical-align: bottom  !important;
    float: none;
}

<table class="table">
<tr><td class="vertical-top" style="height:100px;">Top Align</td></tr>
<tr><td class="vertical-center" style="height:100px;">Center Align</td></tr>
<tr><td class="vertical-bottom" style="height:100px;">Bottom Align</td></tr>
</table>

Try it »


Advertisements

Add Comment

📖 Read More