javascript - IFRAME Height Property Difference Between Safari and Chrome -
i've been tearing out hair on one... maybe can help? height of embedded web app on site looks expected on safari (calculated height 992px), in chrome, iframe containing webapp calculates height 150px, "incorrect".
the height iframe should computed using simple code using javascript, referenced elsewhere on stackexchange:
<script language="javascript" type="text/javascript"> function resizeiframe(obj) { obj.style.height = obj.contentwindow.document.body.scrollheight + 'px'; } </script> <iframe class="embed-blast" src="http://example.com/mywebapp" scrolling="no" onload="resizeiframe(this)" ></iframe>
i've tried using jquery, , variety of other scripts, none of seem fix underlying issue.
what i'd size iframe full content size (as occurs in safari already) in chrome. i've tried looking description of behavior, haven't been able find it. not sure if "bug" or expected behavior-- not having familiarity javascript or iframes, i'm vexed.
is aware of issue , potential workaround? many in advance.
Comments
Post a Comment