Iframe高度自适应
//iframe对象
<iframe id="yearDetail" name="yearDetail" src="" style="overflow:visible;"
scrolling="yes" frameborder="no" width="100%"></iframe>
function reinitIframe(){
var iframe = document.getElementById("yearDetail");
try{
var bHeight = iframe.contentWindow.document.body.scrollHeight;
var dHeight = iframe.contentWindow.document.documentElement.scrollHeight;
var height = Math.max(bHeight, dHeight);
iframe.height = height;
}catch (ex){}
}
window.setInterval("reinitIframe()", 200);