When trying Individual column searching-text inputs, it shows table.columns()is not a function error

When trying Individual column searching-text inputs, it shows table.columns()is not a function error

Arun LalArun Lal Posts: 3Questions: 2Answers: 0

Hi,

I refered below js files,
https://cdn.datatables.net/1.10.12/js/jquery.dataTables.min.js
//code.jquery.com/jquery-1.12.3.js

$(document).ready(function() {

        // DataTable
        var table = $('#leadGrid').dataTable();       ---------->leadGrid is my table ID

        // Apply the search
        table.columns().every( function () {       ------->Error shows in this line.
            var that = this;

            $( 'input', this.footer() ).on( 'keyup change', function () {
                if ( that.search() !== this.value ) {
                    that
                        .search( this.value )
                        .draw();
                }
            } );
        } );
    } );

Please help me.. its very urgent

Answers

This discussion has been closed.