how can remove td cell in table mvc4?
could use jquery or javascript? , if so, how?
<table class="table table-striped table-bordered table-hover" id="tblparticipantlist"> <thead> <tr> <th>name</th> <th>adress</th> <th>redeem code</th> </tr> </thead> <tbody> <tr data-id="columnid" id="customerpartial_94"> <td data-field="name">attn donna</td> <td data-field="address">3046 lavon drive newyork america 7504</td> <td data-field="security_redemption_cd"></td> </tr> <tr data-id="columnid" id="customerpartial_95"> <td data-field="name">f 1 la 1</td> <td data-field="address">asd 1 s 1 ci 1 s</td> <td data-field="security_redemption_cd"></td> </tr> </tbody> </table>
to remove td item, should know td want remove.
remove td item
$('#tblparticipantlist > tr > td').remove();remove td @ specified row
$('#tblparticipantlist > tr').eq(rownum).children('td').remove();remove td @ specified row , column
$('#tblparticipantlist > tr').eq(rownum).children('td').eq(colnum).remove();
Comments
Post a Comment