L
luckydenis2007
I am trying to access image information that is displayed using
iframe.
iframe code looks like this:
<iframe id="testImage" src="/images/someimg.gif" scrolling="yes"
frameborder="0" style="border: 0; width: 280px; height: 455px;"></
iframe>
I need to figure out height of the image.
In Firefox and IE it is not a problem.
document.getElementById('testImage').contentWindow.document.getElementsByTagName('img')
[0].height
document.getElementById('testImage').contentWindow.contentDocument.height
But in Safari contentWindow is undefined.
iframe.
iframe code looks like this:
<iframe id="testImage" src="/images/someimg.gif" scrolling="yes"
frameborder="0" style="border: 0; width: 280px; height: 455px;"></
iframe>
I need to figure out height of the image.
In Firefox and IE it is not a problem.
document.getElementById('testImage').contentWindow.document.getElementsByTagName('img')
[0].height
document.getElementById('testImage').contentWindow.contentDocument.height
But in Safari contentWindow is undefined.