例 2.5(delTRTDIEFF.html)
马克- to-win:马克 java社区:防盗版实名手机尾号: 73203。
    <meta http-equiv="content-type" content="text/html; charset=utf-8"/>

    <TITLE>  </TITLE>
<input id="row" type="text" size="2"/>行,
<input id="dellastrow" type="button" value="删行"/><br/>

<input id="column" type="text" size="2"/>列
<input id="delrowcell" type="button" value="删最后一行的某一格"/><br/><br/>
<TABLE id="test" border="1" style="border-collapse:collapse">
    var tab = document.getElementById("test");
    function dellastrow()
         TABLE.deleteRow(anIndex) (Method)
         Deletes a specified row within the TABLE object.
         Argument list: anIndex The row to delete
        var row = document.getElementById("row").value ;
        tab.deleteRow(row - 1);
    function delrowcell()
        var column = document.getElementById("column").value ;
        var rowList = tab.rows;
        var lastRow = rowList.item(rowList.length - 1);
        /*TR.deleteCell() (Method)
         In a multiple column table, you can delete a particular cell within a row with this method.
        lastRow.deleteCell(column - 1);