10
jQuery在加载时获取iframe内容的高度
我在Main.php的iframe中加载了一个帮助页面help.php,将页面加载到iframe中后,如何获取该页面的高度? 我问这个问题是因为我无法将iframe的高度设置为100%或自动。这就是为什么我认为我需要使用javascript ..我正在使用jQuery CSS: body { margin: 0; padding: 0; } .container { width: 900px; height: 100%; margin: 0 auto; background: silver; } .help-div { display: none; width: 850px; height: 100%; position: absolute; top: 100px; background: orange; } #help-frame { width: 100%; height: auto; margin:0; padding:0; } JS: $(document).ready(function () …