<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>uupaa</author_name>
  <author_url>https://blog.hatena.ne.jp/uupaa/</author_url>
  <blog_title>latest log</blog_title>
  <blog_url>https://uupaa.hatenablog.com/</blog_url>
  <categories>
  </categories>
  <description>iframe 内で発生したページ遷移を親windowで検出し、以前のページを強制的に再表示する例です。 ページ遷移そのものを抑止しているわけではなく、遷移直後にページを戻しています。 短いながらも、なかなかトリッキーなコードです。 index.html (parent window) &lt;html&gt;&lt;body style=&quot;background:lime;width:100%;height:100%&quot;&gt; &lt;iframe id=&quot;iframe&quot; src=&quot;iframe.html&quot; style=&quot;width:300px;height:300px&quot;&gt;&lt;/iframe&gt; &lt;script&gt; var ifr…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fuupaa.hatenablog.com%2Fentry%2F2014%2F09%2F03%2F220936&quot; title=&quot;iframe 内のページ遷移を親 window で検出する - latest log&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url>http://g.recordit.co/W6pv200Mua.gif</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2014-09-03 22:09:36</published>
  <title>iframe 内のページ遷移を親 window で検出する</title>
  <type>rich</type>
  <url>https://uupaa.hatenablog.com/entry/2014/09/03/220936</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
