title: How to get height and width after window resize
body: <p>I have a scorm module which launches in a new window with resizable = 1 in window.open in my js file:</p>
  
  <pre><code>function OpenScormModuleWindow(scormModuleId, scormModuleUrl, title, width, height) 
  {
    _scormModuleId = scormModuleId;
    InitializeUserScormModule();
    scormModuleWindow = window.open(scormModuleUrl, "title", "width=" + width + ", height=" + height + ", resizable = 1");
    scormModuleWindow.focus();
  }
  </code></pre>
  
  <p>in my view I have:</p>
  
  <pre><code>  var myWidth = 0, myHeight = 0;
    if (typeof (window.innerWidth) == 'number')
    {
        myWidth = window.innerWidth;
        myHeight = window.innerHeight;
    }
    else if (document.documentElement &amp;&amp; (document.documentElement.clientWidth || document.documentElement.clientHeight))
    {
        myWidth = document.documentElement.clientWidth; myHeight = document.documentElement.clientHeight;
    }
    else if (document.body &amp;&amp; (document.body.clientWidth || document.body.clientHeight))
    {
        myWidth = document.body.clientWidth; myHeight = document.body.clientHeight;
    }
  </code></pre>
  
  <p>I get height and width but is not correct     </p>
  
  <p>the user can now resize, when the window is the correct size, how can I get the height and width please?</p>
  
  <p>I need to get these values so I can save it, next time the window opens it is the correct size.</p>
  
  <p>thanks</p>