一、Iframe
一、Iframe
自適應iframe的高
<!-- frameborder :設置iframe的邊框scrolling:設置iframe的滾動條src:設置iframe的路徑onload:要設置iframe的自適應,必須設置在行內標簽,通過js設置的話是顯示了之后才進行值的設置,并沒有什么效果 --> <iframe id="userIframe" onload="this.style.height=Math.max(this.contentWindow.document.body.scrollHeight,this.contentWindow.document.documentElement.scrollHeight)+\'px\'" width="100%" height="auto" frameborder="0" scrolling="no" class="router-view-iframe-style" src="home_user_info.html"></iframe>?
轉載于:https://www.cnblogs.com/fger/p/11103715.html
總結
- 上一篇: gitignore
- 下一篇: 笔记-VUE滚动加载更多数据