zoukankan      html  css  js  c++  java
  • 改变框架大小(解决浏览器不识别)

    <frameset name="myFrame" cols="199,7,*" frameborder="no" border="0" framespacing="0" id="myFrame">
        <frame src="leftframe.jsp" name="leftFrame" frameborder="no" scrolling="No" noresize="noresize" id="leftFrame" title="leftFrame" />
    	<frame src="switchframe.html" name="midFrame" frameborder="no" scrolling="No" noresize="noresize" id="midFrame" title="midFrame" />
        <frameset rows="59,*" cols="*" frameborder="no" border="0" framespacing="0">
             <frame src="mainframe.html" name="mainFrame" frameborder="no" scrolling="No"  noresize="noresize" id="mainFrame" title="mainFrame" />
             <frame src="fuwuqi.jsp" name="manFrame" frameborder="no"   id="manFrame" title="manFrame" />
         </frameset>
      </frameset>
    

      

    <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <link rel="stylesheet" href="css/common.css" type="text/css" />
    <title>显示/隐藏左侧导航栏</title>
    </head>
    <script language="JavaScript">
    	function Submit_onclick()
    	{
    		alert(window.parent.document.getElementById("myFrame").cols);
    		if(window.parent.document.getElementById("myFrame").cols == "199,7,*") {
    	        window.parent.document.getElementById("myFrame").cols ="0,7,*";
    	        document.getElementById("ImgArrow").src="images/switch_right.gif";
    	        document.getElementById("ImgArrow").alt="打开左侧导航栏";
    	    } else {
    	        window.parent.document.getElementById("myFrame").cols="199,7,*";
    	        document.getElementById("ImgArrow").src="images/switch_left.gif";
    	        document.getElementById("ImgArrow").alt="隐藏左侧导航栏";
    	    }
    	}
    	window.onload=function()
    	{
    		if(window.parent.location.href.indexOf("MainUrl")>0) 
    		{
    			window.top.midFrame.document.getElementById("ImgArrow").src="images/switch_right.gif";
    		}
    	}
    </script>
    <body >
    <div id="switchpic"><a href="javascript:Submit_onclick()"><img src="images/switch_left.gif" alt="隐藏左侧导航栏" id="ImgArrow" /></a></div>
    </body>
    </html>
    

      

  • 相关阅读:
    c++引用(reference)
    c++ 三目运算符功能增强
    C++ “新增”bool类型关键字
    C++ struct
    C++命名空间(namespace)
    基于python 实现KNN 算法
    Chrome 快捷键使用
    WOE(weight of evidence, 证据权重)
    python 命令运行环境下 ModuleNotFoundError: No module named 'Test'
    基于python 信用卡评分系统 的数据分析
  • 原文地址:https://www.cnblogs.com/xiaofanke/p/3690197.html
Copyright © 2011-2022 走看看