title: Incorrect height of div returned by JS functions. Why?
body: <p>I try to get size of main div on page, to make iframe change its height to content, but <code>document.getElementById("divId").offsetHeight</code> (also try <code>innerHeight</code>) return wrong value. It always returns 247, but in fact page looks like it cut on 75%. I have an idea that page didn't load fully, so I put resize code in the footer of the page, but it still return 247.</p>
  
  <pre><code>$(document).ready(function() {
       console.log(document.getElementById("resizeDiv").offsetHeight);
  });
  </code></pre>
  
  <p>Any suggestions?</p>