鼠标经过切换对应显示内容

<!DOCTYPE html>
  <html>
    <head>
      <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
      <title>鼠标悬浮切换显示</title>
      <!-- js方法 -->
      <script type="application/javascript">
        function ChangeDiv(divId,divName,zDivCount){
          for(i=0;i<=zDivCount;i++){
            document.getElementById(divName+i).style.display="none";
          }
          document.getElementById(divName+divId).style.display="block";
        }
      </script>
    </head>
    <body>
      <table border=0 cellSpacing=0 cellPadding=0 width="100%">
        <tbody>
          <tr height=44 vAlign=top>
            <td><a onmouseover="ChangeDiv(‘0‘,‘JKDiv_‘,2)" href="#">新闻一</a></td>
            <td bgColor=#ffffff width=1></td>
            <td><a onmousemove="ChangeDiv(‘1‘,‘JKDiv_‘,2)" href="#">新闻二</a></td>
            <td bgColor=#ffffff width=1></td>
            <td><a onmousemove="ChangeDiv(‘2‘,‘JKDiv_‘,2)" href="#">新闻三</a></td>
          </tr>
        </tbody>
      </table>
      <table id="JKDiv_0" style="background-color: #0b4ebf;display:block">
        <tbody>
          <tr>
            <td>000</td>
            <td>000</td>
            <td>000</td>
          </tr>
        </tbody>
      </table>
      <table id="JKDiv_1" style="background-color:#3071A9;display:none">
        <tbody>
          <tr>
            <td>111</td>
            <td>111</td>
            <td>111</td>
          </tr>
        </tbody>
      </table>
      <table id="JKDiv_2" style="background-color: #FF0000;display:none">
        <tbody>
          <tr>
            <td>111</td>
            <td>111</td>
            <td>111</td>
          </tr>
        </tbody>
      </table>
    </body>
  </html>

鼠标经过切换对应显示内容

 

鼠标经过切换对应显示内容

上一篇:docker in windows 从入门到放弃(1)——安装


下一篇:Typora简单使用