TypeError: table.columns is not a function

TypeError: table.columns is not a function

kingSulaimankingSulaiman Posts: 3Questions: 2Answers: 0
edited July 2015 in Free community support

I am Using DataTable 1.10.7 and also use $('#example').DataTable(); 2 days I am tring to fix this prob but still can't solve this,
Here is my code :
`

var table = $('#example').dataTable(); 
var i =0;
    $('#TailorTotalReport tfoot th').each( function (i) {
        var title = $('#TailorTotalReport thead th').eq( $(this).index() ).text();
         var totCe = $('#TailorTotalReport thead th').eq( $(this).index() );            
        $(this).html( '<input type="text" placeholder="Search '+title+'" aria-controls="TailorTotalReport" data-column="'+i+'" class="search-input-text srtext" />' );      
    });


    $('.search-input-text').on( 'keyup click', function () {
        var i =$(this).attr('data-column');
        var v =$(this).val();
        table.columns(i).search(v).draw(); 
          });

Is there any other need to install?

Answers

This discussion has been closed.