iframe自适应高度
function iFrameHeight() { var ifm = document.getElementById("mainframe"); var subWeb = document.frames ? document.frames["mainframe"].document : ifm.contentDocument; if (ifm != null && subWeb != null) { ifm.height = subWeb.body.scrollHeight+15; } }