制作带有合并和展开功能的框架

<html>
  <head>
    <title>主框架</title>
    <meta http-equiv=content-type content="text/html;charset=gb2312">   
  </head>
  <frameset border="0" framespacing="0" rows="51,*,0,0" frameBorder="0">
    <frame id="daoHangTiao" name="daoHangTiao" src="daoHangTiao.htm" frameBorder="0" noResize scrolling="no">
    <frameset border="0" name="main" frameSpacing="1" frameBorder="0" cols="503,*" scrolling="auto">
      <frame id="leftFrame" border="0" name="leftFrame" marginWidth="0" frameSpacing="0" marginHeight="0" src="leftFrame.htm" frameBorder="0" scrolling="no">
      <frame id="right" border="0" name="right" frameSpacing="0" src="rightIndex.htm" frameBorder="0">
    </frameset>
    <frame border="0" name="online" frameSpacing="0" src="online.htm" frameBorder="0" noResize scrolling="no">
    <frame border="0" name="function" frameSpacing="0" src="function.htm" frameBorder="0" noResize scrolling="no">
  </frameset>
</html>

<html>
  <head>
    <title>leftFrame</title>
    <script language=javascript>
      function changeWin(){
        if(parent.main.cols!='0,*' && parent.main.cols!='5,*'){
          parent.main.cols='5,*';
          ImgArrow.src="bl_1.gif";
        }else{
          parent.main.cols='503,*';
          ImgArrow.src="al_1.gif";
        }
      }
    </script>
    <meta http-equiv=content-type content="text/html;charset=gb2312">
  </head>

  <body bgColor="#8d989a" leftMargin="0" topMargin="0">
    <table height="100%" cellSpacing="0" cellPadding="0" width="100%" border="0">
      <tbody>
      <tr>
        <td width="100%">
          <iframe id="leftiframe" style="VISIBILITY:inherit;WIDTH:100%;HEIGHT:100%" name="leftiframe" src="leftMain.htm" frameBorder="0">
          </iframe>
        </td>
        <td bgColor="#d0d0c8">
          <table id="td1" height="100%" cellSpacing="0" cellPadding="0" width="100%" bgColor="#d7d8da border="0">
            <tbody>
              <tr>
                <td title="拖动以调整宽度" height="50%">
                </td>
              </tr>
              <tr>
                <td height="96">
                  <img id=ImgArrow onclick=changeWin() alt="展开/关闭帖子列表" src="al_1.gif" width="5" border="0" name="ImgArrow" style="currsor:hand">
                </td>
              </tr>
              <tr>
                <td title="拖动以调整宽度" height="50%">
                </td>
              </tr>
             </tbody>
           </table>
         </td>
      </tr>
      </tbody>
    </table>
  </body>
</html>

posted on 2009-03-25 12:30  李业俊  阅读(252)  评论(0编辑  收藏  举报