<table border="1" width="100%">
  <tr>
    <td width="12%" style="display:none">1 </td>
    <td width="12%">2 </td>
    <td width="12%">3 </td>
    <td width="12%">4 </td>
    <td width="13%">5 </td>
    <td width="13%">6 </td>
    <td width="13%">7 </td>
    <td width="13%">8 </td>
  </tr>
  <tr>
    <td width="12%" style="display:none">1 </td>
    <td width="12%">2 </td>
    <td width="12%">3 </td>
    <td width="12%">4 </td>
    <td width="13%">5 </td>
    <td width="13%">6 </td>
    <td width="13%">7 </td>
    <td width="13%">8 </td>
  </tr>
  <tr>
    <td width="12%" style="display:none">1 </td>
    <td width="12%">2 </td>
    <td width="12%">3 </td>
    <td width="12%">4 </td>
    <td width="13%">5 </td>
    <td width="13%">6 </td>
    <td width="13%">7 </td>
    <td width="13%">8 </td>
  </tr>
  <tr>
    <td width="12%" style="display:none">1 </td>
    <td width="12%">2 </td>
    <td width="12%">3 </td>
    <td width="12%">4 </td>
    <td width="13%">5 </td>
    <td width="13%">6 </td>
    <td width="13%">7 </td>
    <td width="13%">8 </td>
  </tr>
  <tr>
    <td width="12%" style="display:none">1 </td>
    <td width="12%">2 </td>
    <td width="12%">3 </td>
    <td width="12%">4 </td>
    <td width="13%">5 </td>
    <td width="13%">6 </td>
    <td width="13%">7 </td>
    <td width="13%">8 </td>
  </tr>
</table>

解决方案 »

  1.   

    display Attribute | display Property--------------------------------------------------------------------------------Sets or retrieves whether the object is rendered.SyntaxHTML { display : sDisplay }  
    Scripting object.style.display [ = sDisplay ] Possible ValuessDisplay String that specifies or receives one of the following values:block Default. Object is rendered as a block element. 
    none Object is not rendered. 
    inline Default. Object is rendered as an inline element sized by the dimensions of the content. 
    inline-block Object is rendered inline, but the contents of the object are rendered as a block element. Adjacent inline elements are rendered on the same line, space permitting. 
    list-item Object is rendered as a block element, and a list-item er is added. 
    table-header-group Table header is always displayed before all other rows and row groups, and after any top captions. The header is displayed on each page spanned by a table.  
    table-footer-group Table footer is always displayed after all other rows and row groups, and before any bottom captions. The footer is displayed on each page spanned by a table.  
     The property is read/write. The property has a default value of block. The cascading style sheets (CSS) attribute is not inherited. Expressions can be used in place of the preceding value(s), as of Microsoft?Internet Explorer 5. For more information, see Dynamic Properties.ResIn Microsoft?Internet Explorer 4.0, the block, inline, and list-item values are not supported explicitly, but do render the element. The block and inline values are supported explicitly as of Microsoft?Internet Explorer 5.The inline-block value is supported as of Microsoft?Internet Explorer 5.5. You can use this value to give an object a layout without specifying the object's height or width.All visible HTML objects are block or inline. For example, a DIV object is a block element, and a SPAN object is an inline element. Block elements typically start a new line and can contain other block elements and inline elements. Inline elements do not typically start a new line and can contain other inline elements or data. Changing the values for the display property affects the layout of the surrounding content by: Adding a new line after the element with the value block. 
    Removing a line from the element with the value inline. 
    Hiding the data for the element with the value none. In contrast to the visibility property, display??SPAN CLASS="clsLiteral">none reserves no space for the object on the screen.The table-header-group and table-footer-group values can be used to specify that the contents of the THEAD and TFOOT objects are displayed on every page for a table that spans multiple pages.ExampleThis example shows the effect of changing the values for the display property between inline, block, and none.<SPAN ID=oSpan>
    This is a SPAN 
    </SPAN>
    in a sentence.
    <P>
    <INPUT TYPE=button VALUE="Block" 
        onclick="oSpan.style.display='block'">
    :
    Show Me
    This example uses function calls to hide and show table rows and cells.<SCRIPT>
    function getPets()
    {
        oRow1Cell2.style.display="none";
        oRow2Cell2.style.display="block";
        oRow3Cell2.style.display="none";
    }
    </SCRIPT>
    :
    <TABLE>
    <TR ID="oRow1"><TD>Horses</TD>
    <TD ID="oRow1Cell2">Thoroughbreds</TD>
    <TD>Fast</TD></TR>
    <TR ID="oRow2"><TD>Dogs</TD>
    <TD ID="oRow2Cell2">Greyhounds</TD>
    <TD>Fast</TD></TR>
    <TR ID="oRow3"><TD>Marsupials</TD>
    <TD ID="oRow3Cell2">Opossums</TD>
    <TD>Slow</TD></TR>
    </TABLE>
    :
    <INPUT TYPE=button onclick="getPets()" 
        VALUE="Show household pets">
      

  2.   

    <td style="display:none;"></td>