iframe框架調(diào)用高度自適應(yīng)方法_帝國Cms教程
教程Tag:暫無Tag,歡迎添加,賺取U幣!
iframe框架調(diào)用高度自適應(yīng)方法
有需要的可以記錄下來,希望可以幫助到你。
- <iframe frameborder="0" src="http://www.daixiao#/" class="iframe" frameborder="0" id="test" onload="this.height=100" width="762px" scrolling="no"></iframe>
- <script type="text/javascript">
- function reinitIframe(){
- var iframe = document.getElementById("test");
- try{
- var bHeight = iframe.contentWindow.document.body.scrollHeight;
- var dHeight = iframe.contentWindow.document.documentElement.scrollHeight;
- var height = Math.max(bHeight, dHeight);
- iframe.height = height;
- console.log(height);
- }catch (ex){}
- }
- window.setInterval("reinitIframe()", 200);
- </script>
相關(guān)帝國Cms教程:
- 帝國下載不采用彈出窗口式的修改方法
- 帝國CMS全站全文搜索有兩條重復(fù)的原因
- 帝國cms 復(fù)選框字段分隔去掉最后一個值得分隔符
- 帝國cms程序服務(wù)器搬家教程
- 帝國cms后臺標(biāo)題圖片實(shí)現(xiàn)遠(yuǎn)程下載
- 帝國cms內(nèi)容頁文章字?jǐn)?shù)統(tǒng)計(jì)
- 帝國cms模板里顯示發(fā)布信息人的ip地址
- 帝國cms內(nèi)容頁模板顯示作者
- 帝國cms wap里調(diào)用出欄目名稱代碼
- 帝國cms內(nèi)容頁調(diào)用下線時間代碼
- 帝國cms靈動標(biāo)簽調(diào)用復(fù)選框字段去除“|” 符合
- 在帝國cms列表頁調(diào)用內(nèi)容頁內(nèi)容字段newstext
- 相關(guān)鏈接:
- 教程說明:
帝國Cms教程-iframe框架調(diào)用高度自適應(yīng)方法。