title: How to get parent iframe element from inner page without knowing id?
body: <p>Let's imagine that I have something like this:</p>
  
  <pre><code>&lt;html&gt;
  ...
      &lt;div&gt;
          &lt;iframe src="test.html" hash="r4d5f7"&gt;&lt;/iframe&gt;
          &lt;iframe src="test.html" hash="8f7x97"&gt;&lt;/iframe&gt;
          &lt;iframe src="test.html" hash="gg4v5e"&gt;&lt;/iframe&gt;
          &lt;iframe src="test.html" hash="e54f87"&gt;&lt;/iframe&gt;
      &lt;/div&gt;
  ...
  &lt;/html&gt;
  </code></pre>
  
  <p>test.html is empty page, custom <code>hash</code> attribute always has a different value, both pages are on the same domain for security reasons, number and order of iframe elements is random.</p>
  
  <p>My question is: Is there a way to get from inner page (test.html) using Javascript to its proper iframe element? Let's say, I'm in the third iframe's page and I need to get to its iframe element and alert() hash value (in this case "gg4v5e").</p>
  
  <p>To be more specific. If you are familiar with Firefox's Firebug, it visualizes this situation like this:</p>
  
  <pre><code>&lt;html&gt;
  ...
      &lt;div&gt;
          &lt;iframe src="test.html" hash="r4d5f7"&gt;
              &lt;html&gt;
                   ...
              &lt;/html&gt;
          &lt;/iframe&gt;
          &lt;iframe src="test.html" hash="8f7x97"&gt;
              &lt;html&gt;
                   ...
              &lt;/html&gt;
          &lt;/iframe&gt;
          &lt;iframe src="test.html" hash="gg4v5e"&gt;
              &lt;html&gt;
                   ...
              &lt;/html&gt;
          &lt;/iframe&gt;
          &lt;iframe src="test.html" hash="e54f87"&gt;
              &lt;html&gt;
                   ...
              &lt;/html&gt;
          &lt;/iframe&gt;
      &lt;/div&gt;
  ...
  &lt;/html&gt;
  </code></pre>
  
  <p>Is it possible to call "something" in order to get parent element (<code>&lt;iframe&gt;</code>) when I'm with my Javascript at <code>&lt;html&gt;</code> element in inner page?</p>