title: Retrieve URL from iframe using window.postMessage
body: <p>I'm trying to access the URL of an iFrame that I open on my site.  The iFrame is from another domain so traditional methods violate the same origin policy and are flagged as cross site scripting.  However, I just discovered window.postMessage, but I don't quite know how to pull it all together.</p>
  
  <p>My goal is to capture the final URL in the iFrame.  For example, a user clicks a button on my site to open an iFrame.  Say that iFrame loads a web site and the user clicks around on the site.  When they close the iFrame, I want to capture the URL so the next time they click the button on my site, I can open the iFrame to the same state that the site was in last time they visited.  Is this possible with window.postMessage?</p>
  
  <p>Thanks!</p>