title: Is there a way to prevent an iframe from redirecting parent window, but in such a way that "top level" redirects still work inside the iframe itself?
body: <p>So I've read about the <a href="http://www.html5rocks.com/en/tutorials/security/sandboxed-iframes/">HTML5 <code>sandbox</code> property</a> and I understand that if I want to prevent an iframe redirect its parent window I can use the <code>sandbox</code> property leaving <code>allow-top-navigation</code> out. However when this is done, if the iframe was originally relying on top level redirection, what happens in its place is that it redirects to a blank page, effectively breaking navigation.</p>
  
  <p>Can I prevent the iframe from tinkering its parent window while still allowing "top level" redirects, only letting these work within the context of the iframe instead of being top level?</p>
  
  <p>Edit: For context, I'm working with a third party and its page has a form with a target <code>_top</code>. If the iframe is sandboxed, upon submitting the form users get a blank page, if it's <em>not</em> sandboxed the entire page is redirected. I'm looking for something that would allow to submit the form and show the result within the iframe itself.</p>