Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bootstrap 3.0 inline headings tags

I have the following piece of code:

<div class="row">
    <div class="col-md-12">
        <div class="well">
            <div class="clearfix">
                <h2 class="pull-left">Heading</h2>
                <h4>Second Heading</h4>
           </div>
        </div>
     </div>
</div>


The goal is to have both the <h2> and the <h4> next to each other, on the same base line. At this point the <h4> element is way above the line.

I've tried to put this into spans, and other 'tricks' like vertical-align: bottom. For some reason I just simply cannot get this on the same line, and same 'line-height like this:

Heading Second Heading

like image 980
douweegbertje Avatar asked Sep 08 '13 13:09

douweegbertje


1 Answers

Surprised its not been mentioned but another way would be to use the heading classes.

<span class="h2 pull-left">heading</span>
<span class="h4">second heading</span>

See the less file where they typography styles are applied, everything you need apart from the display:block

like image 182
John Magnolia Avatar answered Sep 30 '22 00:09

John Magnolia