title: Move elements to iframe's parent with data and events
body: <p>this is the situation.
  I have a complex UI inside an iframe in which a user can perform several actions before submitting. During the process, the user can switch to another page (in the iframe) and come back. That means 2 postbacks inside the iframe.</p>
  
  <p>Obviously, I don't want the user to lose everything but since all the actions have been done on the client-side, I can't reload the previous state from the server.</p>
  
  <p>So now, I'm trying to move the first page content to the iframe parent and put it back in place when we come back. I'm half way there since the elements show back in the page but they lose their data attributes and event handlers.</p>
  
  <p>I'm using this to move the content on the parent :</p>
  
  <pre><code>$("#resp").clone(true).attr("id", "refillResp").appendTo(window.top.$("#global"));
  </code></pre>
  
  <p>And this to put it back :</p>
  
  <pre><code>window.top.$("#global").find("#refillResp").clone(true).attr("id", "resp").appendTo($("#tdResp"));
  </code></pre>
  
  <p>Is there anyone who knows a way to do this ?
  PS: I've tested how the content react when simply moved on the parent and data and events are already gone.</p>