title: Vertically align text within div element
body: <p>I know this question has been asked to death but nothing through searching has worked for me.</p>
  
  <p>You know the deal, I have a div element that I need to vertically align text in but nothing has worked (position:absolute;top:50%;margin-top:-x;display:table-cell;vertical-align:middle;etc., etc.)</p>
  
  <p>Here is what I am working with (sorry for the inline CSS).  Anyway, the I would use line-height but the text can be one or two lines.  It should vertical align with the image which is always max-height of 30px (30x50).</p>
  
  <pre><code> &lt;div style="margin:0 0 10px 0;padding:10px;border:2px solid #606060;background-color:#2b2b2b;-webkit-border-radius:8px;-moz-border-radius:8px;border-radius:8px;"&gt;
   &lt;div style="float:left;width:55px;height:40px;"&gt;
   &lt;a href="link"&gt;&lt;img style="max-width:50px;border:1px solid #ffb92c;" src="image.jpg" alt="" /&gt;&lt;/a&gt;
   &lt;/div&gt;
   &lt;div style="float:right;width:155px;font-size:0.7em;height:40px;"&gt;
   &lt;a href="link"&gt;This is the text to vertically align&lt;/a&gt;
   &lt;/div&gt;
   &lt;/div&gt;
  </code></pre>