Skip to content

TypeError: dt is undefined (when using without datatable) #28

@char101

Description

@char101

Hi,

I was using this code to initialize FixedHeader

$('table.table-fixed-header').each(function() {
    new FixedHeader(this);
});

And got that error, which comes from these lines

var dt = $.fn.dataTable.Api ?
        new $.fn.dataTable.Api( mTable ).settings()[0] :
        mTable.fnSettings();

    dt._oPluginFixedHeader = this;

    /* Let's do it */
    this.fnInit( dt, oInit );

I was using datatable and fixedheader from the master branch.

Is my initialization code wrong or is this a bug?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions