Iframe automáticoThere are no translations available.
Script rápido que muita gente procura e fica brigando com códigos gigantescos:
<script type='text/javascript'>
function iframeAutoHeight(quem,heu){
//by Micox - elmicox.blogspot.com - elmicox.com - webly.com.br
if(navigator.appName.indexOf("Internet Explorer")>-1){ //ie sucks
var func_temp = function(){
var val_temp = quem.contentWindow.document.body.scrollHeight + 5
quem.style.height = val_temp + "px";
alert(val_temp) }
setTimeout(function() { func_temp() },100) //ie sucks
}else{
var val = quem.contentWindow.document.body.parentNode.offsetHeight + 5
quem.style.height= val + "px";
}
}
</script>
<iframe id='ha' src='teste.php' onload='iframeAutoHeight(this)' frameborder='0'></iframe>
Add new comment
Last Updated (Saturday, 10 July 2010 01:51) |
Copyright © 2010 ---.
Todos direitos reservados
Designer Benício Silva.

