div中显示页面

来源:互联网 发布:360解压缩mac版 编辑:程序博客网 时间:2024/04/19 07:45


   在css中显示页面,在页面布局中很多时候都要在一个div 里显示某些页面。在这里写下我用到的一种方式。

    <script type="text/javascript">
   function theforever(a){
     document.getElementById("rigth-content").innerHTML='<iframe src="'+a.href+'"  width=100%  height=100%   frameborder="1"  marginheight="0"       marginwidth="0" style="border:0px none transparent"></iframe>';
     a.href="#";
    }
</script>

    <div id="rigth-content" ></div>

0 0