DataTables logo DataTables

via Ad Packs
Multiple table w/ addrow and deleterow functions
  • foimystfoimyst
    Posts: 10
    Sorry if repost.... I couldn't get this... It took me a whole day but nothing works... read some of the post on this forum still I can't do it... I do think Im a slow learner... Please HELP me

    Sample table(both table1 and table2) should look something like:
    Name
    ImANoob moveToTable1

    I think the algorithm is like this..
    		var oTable;;
    			$(document).ready(function() {
    				oTable = $('.dataTable').dataTable();
    			} );
    
    		/* Add a click handler for the delete row */
    		$('#moveToTable2').click( function() {
    			oTable.dataTableExt.iApiIndex=0;
    			var nTr = oTable.fnGetData(this);
    			oTable.fnDeleteRow( nTr );
    			oTable.dataTableExt.iApiIndex=1;
    			oTable.fnAddRow( nTr );
    		} );
    
This discussion has been closed.
← All Discussions

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Support

Get useful and friendly help straight from the source.