title: Opening html modal dialog
body: <p>I need to get the contents below on a modal window. I had been trying this for a while today.
  On modal window opened the background body contents are not accessible and on reload page the modal popup should close down leaving the contents of the text area as it is.</p>
  
  <pre><code>&lt;a href="" id="link"&gt;Open Popup&lt;/a&gt;
  &lt;table&gt;
      &lt;tr width="10%"&gt;
          &lt;td&gt;
              &lt;TEXTAREA name="text1" id="text1" rows="15" cols="65" onscroll="sync();" spellcheck="false"&gt;&lt;/TEXTAREA&gt;
          &lt;/td&gt;
          &lt;td&gt;
              &lt;TEXTAREA Name="text2" id="text2" rows="15" cols="65"  spellcheck="false"&gt;&lt;/TEXTAREA&gt;
          &lt;/td&gt;
      &lt;/tr&gt;
      &lt;tr width="90%"&gt;
          &lt;td&gt;&lt;/td&gt;
      &lt;/tr&gt;
  &lt;/table&gt;
  &lt;input type="button" value="Compile" onclick="stat('')"/&gt;
  &lt;input type="button" value="Reload Page" onClick="window.location.href=window.location.href"&gt;
  </code></pre>