Get Data from row after searching, how?

Get Data from row after searching, how?

lester143lester143 Posts: 2Questions: 1Answers: 0

Hi guys,

I have successfully get data from the row of first 10rows but the problem is when I'm searching the specific record & won't get the data.

here's code:

$(document).ready(function() {
oTable = $('#datatables').dataTable();

      oTable.$('tbody tr').click( function () {
        var sData = oTable.fnGetData( this );

        document.getElementById('test1').value      = sData[1];                    
        document.getElementById('test2').value      = sData[2];
                document.getElementById('test3').value          = sData[3];
        });
    });

I have create button at the last column which when I click the button, it will get the data from the specific row.

How can I achieve this?

thanks,
lester

This discussion has been closed.