title: how to find real DIV height?
body: <p>I have the following html structure:</p>
  
  <pre><code>&lt;div id="container"&gt;
       &lt;h1&gt;This is an h1 element&lt;/h1&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>When I try to find the height of the container in firefox or chrome div using javascript:</p>
  
  <pre><code>var container = document.getElementById("container");
  var offsetHeight = container.offsetHeight;
  </code></pre>
  
  <p>I get the wrong offsetHeight (also if used with clientHeight).
  I get only the height of the H1 itself and not the margin-before/margin-after that surround the element.</p>
  
  <p>is there any way to get the real height?</p>