title: Getting a Google Form in an IFrame with Auto Height
body: <p>So I have a form that I built with Google Docs because it seemed easier than going from scratch. I've gotten this to work by copy-pasting the code from google's page to one on my domain.</p>
  
  <p>I managed to get it to auto-size its height with this lovely little script I found here: <a href="http://www.frontpagewebmaster.com/m-89000/tm.htm" rel="noreferrer">http://www.frontpagewebmaster.com/m-89000/tm.htm</a> (this is not another thread about HOW to dynamically resize an iframe)</p>
  
  <pre><code>function changeContent() { 
  document.getElementById('contentDIV').innerHTML = window.frames['contentFRAME'].document.getElementsByTagName('html')[0].innerHTML;
  } 
  </code></pre>
  
  <p>and the iframe on MY displayed page:</p>
  
  <pre><code>&lt;div class="right" id="contentDIV"&gt;
  &lt;iframe id="contentFRAME" src="raw-form.html" name="contentFRAME" onLoad="changeContent()" style="height:0; width:0; border-width:0;"&gt;Loading...&lt;/iframe&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>But now when I hit submit, the confirmation or error page opens in the _parent window (might be _top) - instead of in the iframe (_self, which is supposed to be the default?). target="" is depreciated and doesn't work. This also happens with ANY link inside the iframe.
  I've tried a couple different resize scripts, but I don't know enough to figure it out? Or the code doesn't actually work for my purposes? I'm not sure... Here's what I have working: <a href="http://fiendconsulting.com/60minutedesign/form-embed.html" rel="noreferrer">http://fiendconsulting.com/60minutedesign/form-embed.html</a></p>
  
  <p><strong>What I need</strong>: Something that resizes the iframe content on first load of the Parent page and which opens all links in their _self frame/page/whatever.<br>
  <strong>What I don't care about</strong>: Resizing the iframe to fit the content of subsequent pages. If I click a link inside the iframe, I don't need the iframe to resize to whatever page I just went to.</p>
  
  <p>I'm a self-taught programmer and I have some interesting gaps in my knowledge. I also just started learning JS and PHP and am at the Read, Comment and Cannibalize stage. It's better to assume I don't know, and it would help me a LOT if you told me where to Put the code  (which document and where in the document). :)</p>